Closed
Bug 386855
Opened 18 years ago
Closed 18 years ago
attachment file name stripped of consecutive spaces
Categories
(Thunderbird :: Mail Window Front End, defect)
Thunderbird
Mail Window Front End
Tracking
(Not tracked)
VERIFIED
FIXED
Thunderbird 3
People
(Reporter: pete.bannister, Assigned: whimboo)
References
Details
(Keywords: verified1.8.1.8)
Attachments
(2 files, 2 obsolete files)
4.04 KB,
patch
|
Bienvenu
:
review+
mscott
:
superreview+
|
Details | Diff | Splinter Review |
4.96 KB,
patch
|
whimboo
:
review+
whimboo
:
superreview+
mscott
:
approval1.8.1.8+
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CLR 1.1.4322; .NET CLR 2.0.50727; FDM)
Build Identifier: version 2.0.0.4 (20070604)
Receiving a mail with more than one consecutive space in an attachment filename and then saving to disk strips down the consecutive spaces to a single space. e.g. the filename "4 spaces.txt" becomes "4 spaces.txt". This occurs with mails sent from Thunderbird or Outlook. Sending a mail from thunderbird TO outlook does not appear to have the problem.
Reproducible: Always
Steps to Reproduce:
1. Create a text file with consecutive spaces "4 spaces.txt"
2. Send as an attachment to self
3. Save the attachment and inspect the filename
Actual Results:
"4 spaces.txt" becomes "4 spaces.txt"
Expected Results:
Attachment filenames should not be modified.
Originally seen with a 1.5x version. Upgraded to version 2.0.0.4 (20070604) which still has the bug.
Assignee | ||
Comment 1•18 years ago
|
||
I can see this behavior with Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-US; rv:1.9a6pre) Gecko/20070622 Thunderbird/3.0a1pre ID:0000000000 [cairo]
As it looks like the spaces are getting stripped while the file is attached. If you open the sent folder after the message is sent the attachment only contains one space character.
Cannot find any other bug which handles the same issue.
Severity: major → minor
Status: UNCONFIRMED → NEW
Component: General → MailNews: Attachments
Ever confirmed: true
OS: Windows XP → All
Product: Thunderbird → Core
QA Contact: general → attachments
Version: 2.0 → Trunk
Interestingly though - if I send the attachment from thunderbird to a different mail client then the spaces are not stripped off. Presumably it is down to the code that reads the mail and extracts the attachment file name (I'm assuming here that the sent box reuses the code that the inbox uses for parsing mails)?
Updated•18 years ago
|
Severity: minor → major
Component: MailNews: Attachments → General
OS: All → Windows XP
Product: Core → Thunderbird
Version: Trunk → 2.0
Comment 3•18 years ago
|
||
Sorry, certainly didn't mean to do *those* changes...
Component: General → MailNews: Attachments
Product: Thunderbird → Core
Version: 2.0 → 1.8 Branch
Updated•18 years ago
|
Severity: major → minor
Assignee | ||
Updated•18 years ago
|
OS: Windows XP → All
Version: 1.8 Branch → Trunk
![]() |
||
Comment 4•18 years ago
|
||
I just tested this on Linux with SeaMonkey branch (XUL filepicker), trunk (GTK2 filepicker) and Thunderbird trunk (GTK2 filepicker), and it fails only in Thunderbird, maybe due to the different attachment pane, where it's already differently displayed (SeaMonkey always displays all spaces, Thunderbird only one).
Assignee | ||
Comment 5•18 years ago
|
||
Thanks Robert. Meanwhile I checked my MBOX file and noticed that this isn't a backend problem. It seems that Thunderbird can't display multiple blanks.
Component: MailNews: Attachments → Mail Window Front End
Product: Core → Thunderbird
QA Contact: attachments → front-end
Hardware: PC → All
Assignee | ||
Comment 6•18 years ago
|
||
Attachment part of the message:
Content-Type: text/plain; x-mac-type="0"; x-mac-creator="0";
name="test tz"
Content-Transfer-Encoding: base64
Content-Disposition: inline;
filename="test tz"
Assignee | ||
Comment 7•18 years ago
|
||
David, why do we remove multiple blanks from displayName? I know that shortens up the text but it also shows a modified filename. We shouldn't patronize the user.
Assignee | ||
Updated•18 years ago
|
Attachment #271130 -
Flags: review? → review?(bienvenu)
Comment 8•18 years ago
|
||
Comment on attachment 271130 [details] [diff] [review]
No removal of additional blanks
This was added intentionally, pleae don't undo it. In the future you can use CVS blame so see why code was added :)
This is for Bug 300246.
Attachment #271130 -
Flags: review?(bienvenu) → review-
Comment 9•18 years ago
|
||
yeah, what Scott said :-)
Reporter | ||
Comment 10•18 years ago
|
||
So its not a bug its a feature! :grin:
I can see why it is useful when displaying the filename, but not when the file is stored to disk.. I'm maintaining an application where files can have spaces in the extension - if they are stipped then file filtering does not work correctly.
Assignee | ||
Comment 11•18 years ago
|
||
This patch observes the security issue of bug 300246 and only displays the shortened filename within the attachment pane. The tooltext still shows the full name and you are also able to save the file with the correct name. This is the spun off patch from attachement 271260 which is for MailNews.
Attachment #271130 -
Attachment is obsolete: true
Attachment #271275 -
Flags: superreview?(bienvenu)
Attachment #271275 -
Flags: review?(mscott)
Reporter | ||
Comment 12•18 years ago
|
||
Nice 1 :)
Comment 13•18 years ago
|
||
Comment on attachment 271275 [details] [diff] [review]
Patch v2: Only shorten the display name
what about things like the attachment menu? Is the display name used to construct the menu? Do we care?
Assignee | ||
Comment 14•18 years ago
|
||
(In reply to comment #13)
> what about things like the attachment menu? Is the display name used to
> construct the menu? Do we care?
Oh, thanks David! I was never in touch with that menu. I'll come up with an updated version.
Depends on: sa15907
Assignee | ||
Comment 15•18 years ago
|
||
Ok, this fixes the remaining issue now. If we need to display the attachment name once more we can rely on the new function createAttachmentDisplayName.
Attachment #271275 -
Attachment is obsolete: true
Attachment #271710 -
Flags: superreview?(mscott)
Attachment #271710 -
Flags: review?
Attachment #271275 -
Flags: superreview?(bienvenu)
Attachment #271275 -
Flags: review?(mscott)
Assignee | ||
Updated•18 years ago
|
Attachment #271710 -
Flags: review? → review?(bienvenu)
Comment 16•18 years ago
|
||
Comment on attachment 271710 [details] [diff] [review]
Patch v3 also fixes the attachment menu
thx, Henrik.
Attachment #271710 -
Flags: review?(bienvenu) → review+
Assignee | ||
Comment 17•18 years ago
|
||
I raise the priority because we currently mangle the filename. Would this be a fix we would like to have for branch 1.8? If yes, I think it's too late for 1.8.1.5?
Severity: minor → normal
Comment 18•18 years ago
|
||
it's probably too late for 1.8.1.5, but I think we'd consider it for a future 1.8 branch build. You could nominate it for 1.8.1.6, after it's been checked into the trunk and baked for a while.
Assignee | ||
Comment 19•18 years ago
|
||
Scott, could you please super-review my patch?
Assignee | ||
Comment 20•18 years ago
|
||
FYI: The appropriate patch for SeaMonkey on bug 300246 was checked in 5 days ago.
Comment 21•18 years ago
|
||
Comment on attachment 271710 [details] [diff] [review]
Patch v3 also fixes the attachment menu
thanks henrik.
Attachment #271710 -
Flags: superreview?(mscott) → superreview+
Assignee | ||
Updated•18 years ago
|
Keywords: checkin-needed
Comment 22•18 years ago
|
||
Landed on trunk.
Assignee | ||
Comment 23•18 years ago
|
||
Pete, could you test a tomorrows trunk nightly build if it fixes the issue for you? If yes, then use a fresh profile to not destroy your working one. If all is fine I'll ask for 1.8 approval.
Target Milestone: --- → Thunderbird 3
Assignee | ||
Comment 24•18 years ago
|
||
Verified with version 3.0a1pre (2007072105).
Status: RESOLVED → VERIFIED
Assignee | ||
Updated•18 years ago
|
Attachment #271710 -
Flags: approval1.8.1.6?
Assignee | ||
Updated•18 years ago
|
Attachment #271710 -
Flags: approval1.8.1.6?
Assignee | ||
Comment 25•18 years ago
|
||
The patch doesn't apply well on 1.8 Branch. Here is the updated version of Patch v3 which is already checked into trunk. Carrying over r/sr because there are made no changes to the code.
Attachment #273249 -
Flags: superreview+
Attachment #273249 -
Flags: review+
Attachment #273249 -
Flags: approval1.8.1.6?
Updated•17 years ago
|
Attachment #273249 -
Flags: approval1.8.1.7? → approval1.8.1.7+
Assignee | ||
Updated•17 years ago
|
Keywords: checkin-needed
Comment 26•17 years ago
|
||
Attachment 273249 [details] [diff] landet on MOZILLA_1_8_BRANCH.
Keywords: checkin-needed → fixed1.8.1.7
Assignee | ||
Comment 27•17 years ago
|
||
Works fine for Thunderbird version 2.0.0.7pre (20070913). Now we are on a secure way even on 1.8 branch.
Keywords: fixed1.8.1.8 → verified1.8.1.8
You need to log in
before you can comment on or make changes to this bug.
Description
•