[OpenAFS-devel] Why does default_com_err_proc() spit out a carriage
return?
Jeffrey Altman
jaltman@secure-endpoints.com
Thu, 04 Nov 2010 15:49:32 -0400
This is an OpenPGP/MIME signed message (RFC 2440 and 3156)
--------------enig38D40AB57EB493E4D73C7FD2
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
On 11/4/2010 3:30 PM, Phillip Moore wrote:
> Does anyone know why, in src/comerr/com_err.c,
> in default_com_err_proc(), the code does the following:
>=20
> putc('\n', stderr);
> /* should do this only on a tty in raw mode */
> putc('\r', stderr);
> fflush(stderr);
>=20
This should be:
/* should do this only on a tty in raw mode */
putc('\r', stderr);
putc('\n', stderr);
fflush(stderr);
since the CR always is before the LF. MIT fixed this in their code base
more than a decade ago. OpenAFS inherited the brokenness.
Whether OpenAFS wishes to output as CR-LF at all is a separate matter.
I suspect the answer should be 'no'.
Jeffrey Altman
--------------enig38D40AB57EB493E4D73C7FD2
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
iQEcBAEBAgAGBQJM0w5OAAoJENxm1CNJffh4rcwIAIa8eC9U8yhjlYmduB8sh+8J
7z7MceOX2mx/uwEYaJtwjMDjwIM+D4ihNR7D6nsQhKBQ75ci2WuvPNpi7hiTmfgV
rg9BXX7zAueFY9AsTmtWdyzVz/QNpoMZuCkb5QwmVDgxZ2EEnyIW9/rpsjYZKgDk
P1fO51lK1xTtE+/RNfWQkRhbXaQnw3GHNJhNtNeTBl9FbOKDe2ONMUqicb/L8qqq
Mh8j7G9HaGk7ogQgHvZ9sKw+mFlRTUOaBsGFNX8s36sjlwOR4cSrnaI/Ocbvkgw+
sXvwfVeIuwNXW7XdDUpEmCbAnvnt7psMMo6oUQjhV3G3xUnpjJbplrCAsTeyWQ4=
=41L+
-----END PGP SIGNATURE-----
--------------enig38D40AB57EB493E4D73C7FD2--