Closed Bug 1747828 Opened 2 years ago Closed 2 years ago

File extension truncated when saving an attachment with a different filename

Categories

(Thunderbird :: Untriaged, defect)

Thunderbird 91
defect

Tracking

(Not tracked)

RESOLVED WORKSFORME

People

(Reporter: maxframes, Unassigned)

References

Details

(Keywords: regression)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:95.0) Gecko/20100101 Firefox/95.0

Steps to reproduce:

The issue affects Thunderbird 91.4.1 running on Windows 10 21H2.
Make sure Windows explorer is set to display file extensions; Launch Thunderbird; select a message with an attachment; make sure Thunderbird is set up to "ask every time" when the user double clicks an attachment of that kind; click the attachment; choose "save" in the dialog; replace the filename with something else (don't manually add an extension and don't touch the "save as" file type drop-down menu; save the file.

Actual results:

The attachment is saved with the manually typed filename, but the first character of the extension is missing (so for example .jpg becomes .pg, .mp4 becomes .p4 and .pdf becomes .df); the file icon is the generic blank one and the file can't be opened in the default handler by double clicking it.
Note: if the attachment is saved without manually changing its name, the issue does not occur; if the attachment is saved by clicking on the "save" button next to the attachment (regardless of if it's renamed or not) the issue does not occur. The issue only occurs if the user first clicks on the attachment, and then chooses to save it, and renames it before saving it.

Expected results:

The attachment should have been saved with the correct, complete extension.

Windows 10
Thunderbird 91.4.1 (win64)
Confirm. Following same instructions as provided by reporter, I can reproduce this.
Attachment called 'IMG_9100.JPG'
edited filename : testimage
Save as type: JPEG Image (*JPG)
Resulting save is 'testimage.PG'
Result filename extension is truncated.

If you follow same process, but do not edit the filename:
Attachment called 'IMG_9100.JPG'
Leave unedited filename: 'IMG_9100.JPG'
Save as type: JPEG Image (*JPG)
Resulting save is 'IMG_9100.JPG'
Result no truncating of filename extension

If you follow instructions, but only edit the part before the extension:
Attachment called 'IMG_9100.JPG'
edited filename: testimage.JPG
Save as type: JPEG Image (*JPG)
Resulting save is 'testimage.JPG'
Result no truncating of filename extension

So this only occurs where user chooses to edit the filename and removes the extension completely from filename, thus relying on the 'Save as Type' to insert extension.

Keywords: regression

Hi,
seems that in version 91.11.0 the problem is solved :-)

Status: UNCONFIRMED → RESOLVED
Closed: 2 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.