Closed
Bug 61748
Opened 24 years ago
Closed 24 years ago
signature file is truncated
Categories
(MailNews Core :: Composition, defect, P3)
Tracking
(Not tracked)
VERIFIED
FIXED
People
(Reporter: colin, Assigned: bugzilla)
Details
Attachments
(2 files)
1.20 KB,
patch
|
Details | Diff | Splinter Review | |
1.19 KB,
patch
|
Details | Diff | Splinter Review |
After configuring a signature file, only the first line of text from that file
is ever used. Is the first line is empty, then you don't see any text from the
signature file (although you do still get the "--" at the end of the mail).
Reporter | ||
Comment 1•24 years ago
|
||
For the signature file to be completely read, it has to be in STREAM-LF format.
If its in VARIABLE LENGTH format then only the first line is used. So the
workaround is to convert your signature file to STREAM-LF format. For example:
$ create stmlf.fdl
RECORD
FORMAT stream_lf
$ convert /fdl=stmlf old-sig.txt new-sig.txt
Status: NEW → ASSIGNED
Reporter | ||
Comment 2•24 years ago
|
||
The problem is this. The signature file is read using
nsMsgCompose::LoadDataFromFile, and the way LoadDataFromFile is coded (see
http://lxr.mozilla.org/seamonkey/source/mailnews/compose/src/nsMsgCompose.cpp#19
69), it only makes ONE read to the file. If it doesn't get the entire contents
in that one read, then tough, the remainder is ignored. On OpenVMS, when reading
VARIABLE LENGTH format files, only one line is returned with each read
operation. Hence the problem.
The correct fix (for all platforms since read does not guarantee to read all the
requested characters in one operation) is to loop until either readSize chars
are read or until EOF is hit (read returns 0).
Reporter | ||
Comment 3•24 years ago
|
||
Re-assigned to MailNews default owner. If you want me to submit a patch for this
let me know.
Colin.
Assignee: colin → ducarroz
Status: ASSIGNED → NEW
Assignee | ||
Comment 4•24 years ago
|
||
patches are always welcome...
Reporter | ||
Comment 5•24 years ago
|
||
Reporter | ||
Comment 6•24 years ago
|
||
Reporter | ||
Comment 7•24 years ago
|
||
Patches only tested on OpenVMS.
Assignee | ||
Comment 8•24 years ago
|
||
Will look at it very soon...
Assignee | ||
Comment 9•24 years ago
|
||
I've just tested it on Mac and it works well, even when I simulate a read in
several part (like does apparently OpenVMS). R=ducarroz
Whiteboard: Fix in hand
Comment 10•24 years ago
|
||
sr=bienvenu
Comment 11•24 years ago
|
||
sr=mscott
Assignee | ||
Comment 12•24 years ago
|
||
Fixed and checked in. Thanks colin@theblakes.com for providing the patch.
Status: ASSIGNED → RESOLVED
Closed: 24 years ago
Resolution: --- → FIXED
Whiteboard: Fix in hand
Fix is in, no regression reported, VERIFIED.
Status: RESOLVED → VERIFIED
Updated•20 years ago
|
Product: MailNews → Core
Updated•17 years ago
|
Product: Core → MailNews Core
You need to log in
before you can comment on or make changes to this bug.
Description
•