On Sat, 17 Dec 2011 m...@freebsd.org wrote:

On Sat, Dec 17, 2011 at 1:54 PM, Dimitry Andric <d...@freebsd.org> wrote:
On 2011-12-17 22:32, m...@freebsd.org wrote:
...
?In usr.bin/csup/auth.c, use the correct number of bytes for zeroing the
?shared secret, and use long long format to snprintf a time_t.
If casting is necessary, style prefers intmax_t or uintmax_t, since
those are always wide enough.

I don't see anything about that in style(9), maybe it should be added
then?

style(9) decoments the uncouthness of long long and %lld by providing
no examples of them.  Unfortunately for my cause, it also provides no
examples of intmax_t.  It is basically just too old to provide examples
of either.

Probably; Bruce has mentioned it many times in the past, and as bz@

I tried to get [u]intmax_t used, and [unsigned] long long and [u]quad_t
killed, before C99, so that FreeBSD would never use the long long
abomination.  There was a problem printing the [u]intmax_t's before
C99.  I don't remember anything that would have worked except %q, and
in userland, also %ll.  %ll was intentionally left out of the kernel
printf(), but this has been broken.

notes, it's a well-defined type with a well-defined conversion
specifier.  Also, long long is a bit of a hack that came in before C99

s/a bit of/gross/

standardized on a few wider types, and the PRIu64 macros are really
hideous.

Bruce
_______________________________________________
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to