Commit notifications for all Sup repositories
 help / color / mirror / Atom feed
From: Dan Callaghan <dan@bl2.djc.id.au>
To: sup-commits@supmua.dev
Subject: [sup.git] 03/03: strip out slashes in attachment filenames for fallback text-view mode
Date: Fri, 20 Nov 2026 21:38:00 +1100	[thread overview]
Message-ID: <20261120103758.39D512D09E8@bl2.djc.id.au> (raw)
In-Reply-To: <179517107783.237609.3020024330765005481@bl2.djc.id.au>

New commit on branch develop:
https://supmua.dev/git/sup/commit/ab44ffd77b4729fd633086f32076d3f1b89b2fb1.html

commit ab44ffd77b4729fd633086f32076d3f1b89b2fb1
Author: Dan Callaghan <djc@djc.id.au>
AuthorDate: Fri Nov 20 21:20:57 2026 +1100

    strip out slashes in attachment filenames for fallback text-view mode
---
 lib/sup/modes/thread_view_mode.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/sup/modes/thread_view_mode.rb b/lib/sup/modes/thread_view_mode.rb
index 33ee39e1..0db03f4f 100644
--- a/lib/sup/modes/thread_view_mode.rb
+++ b/lib/sup/modes/thread_view_mode.rb
@@ -1027,7 +1027,7 @@ private
     BufferManager.erase_flash
     BufferManager.completely_redraw_screen
     unless success
-      BufferManager.spawn "Attachment: #{chunk.filename}", TextMode.new(chunk.to_s.ascii, chunk.filename)
+      BufferManager.spawn "Attachment: #{chunk.filename}", TextMode.new(chunk.to_s.ascii, chunk.filesafe_filename)
       BufferManager.flash "Couldn't execute view command, viewing as text."
     end
   end

      parent reply	other threads:[~2026-11-20 10:37 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-20 10:37 [sup.git] branch develop updated (154ff507 -> ab44ffd7) Dan Callaghan
2026-11-20 10:37 ` [sup.git] 01/03: tests: add thread-view-mode test for attachment filename escaping Dan Callaghan
2026-11-20 10:37 ` [sup.git] 02/03: strip out slashes in attachment filenames when saving to dir Dan Callaghan
2026-11-20 10:38 ` Dan Callaghan [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261120103758.39D512D09E8@bl2.djc.id.au \
    --to=dan@bl2.djc.id.au \
    --cc=djc@djc.id.au \
    --cc=sup-commits@supmua.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox