[14877] in Athena Bugs
Re: sgi 8.0I: from -r garbles subject lines
daemon@ATHENA.MIT.EDU (Mark Eichin)
Wed Dec 11 19:20:44 1996
To: Greg Hudson <ghudson@MIT.EDU>
Cc: "Bruce R. Lewis" <brlewis@MIT.EDU>, bugs@MIT.EDU, source-reviewers@MIT.EDU
In-Reply-To: Greg Hudson's message of Tue, 10 Dec 1996 20:57:06 EST
From: Mark Eichin <eichin@MIT.EDU>
Date: 10 Dec 1996 22:17:51 -0500
> examining the code, it appears that there's already a buf1[0] = '\0';
> after the conditional, so the memset or calloc would be redundant, and
> thus are likely to be unrelated to the bug...
Sigh. The memset or calloc would, instead make the buf1[0] assignment
redundant... as would changing
if (subject_field)
strncpy(buf1, subject_field, winlength - len - 1);
to
if (subject_field) {
strncpy(buf1, subject_field, winlength - len - 1);
buf1[winlength - len - 1] = 0;
}