-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 According to Bruno Haible on 8/22/2007 3:25 PM: >> >> - if (*lineptr == NULL || *n == 0) >> + if (*n == 0) > > This is a behaviour change: Previously when *lineptr == NULL, *n did not > need to be initialized. Now it needs to be initialized to 0. Should be > mentioned in NEWS.
Hmm, I agree. But the wording the draft 3 of POSIX 200x requires *n to be initialized - if it is non-zero, then *lineptr must point to that many bytes, so *n must be 0 if *lineptr is NULL when used in a manner compliant with POSIX. Maybe it is worth a question on the Austin group mailing list as to whether this is intentional? Or do we go ahead and be generous by resetting *n to a sane value when *lineptr is NULL (ie. revert this one line)? - -- Don't work too hard, make some time for fun as well! Eric Blake [EMAIL PROTECTED] -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.5 (Cygwin) Comment: Public key at home.comcast.net/~ericblake/eblake.gpg Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFGzNA784KuGfSFAYARAmQeAJ41dT8abUd991cOKHxciQIro8dCfgCgqNsv gxWCa3449T1Cv7vIpHiVU7s= =cqbs -----END PGP SIGNATURE-----