Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 17 Dec 2011 21:59:13 +0000
From:      "Bjoern A. Zeeb" <bzeeb-lists@lists.zabbadoz.net>
To:        Dimitry Andric <dim@FreeBSD.org>
Cc:        svn-src-head@freebsd.org, mdf@FreeBSD.org, svn-src-all@freebsd.org, src-committers@freebsd.org
Subject:   Re: svn commit: r228625 - head/usr.bin/csup
Message-ID:  <398125AD-ECC7-42EB-8050-BAEC6F444F1C@lists.zabbadoz.net>
In-Reply-To: <E64E9703-3032-4AFA-BAA4-BC4552AFC3C7@lists.zabbadoz.net>
References:  <201112171314.pBHDEjtQ060509@svn.freebsd.org> <CAMBSHm9cBbCxZ9MvgPvKgYfSxPSpeofgTq0NnJo=e3tR5idxEQ@mail.gmail.com> <4EED0F99.2020306@FreeBSD.org> <E64E9703-3032-4AFA-BAA4-BC4552AFC3C7@lists.zabbadoz.net>

next in thread | previous in thread | raw e-mail | index | archive | help

On 17. Dec 2011, at 21:56 , Bjoern A. Zeeb wrote:

>=20
> On 17. Dec 2011, at 21:54 , Dimitry Andric wrote:
>=20
>> On 2011-12-17 22:32, mdf@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.
>>=20
>> I don't see anything about that in style(9), maybe it should be added
>> then?  In any case, I only changed the %ld format to %lld, because
>> time_t is int, long or long long depending on arch.  Long long is =
just
>> the widest type required in this case.
>=20
> time_t is not always int.  See sparc64.

gnargh, sorry.  But yes we prefer a well defined type to a type that is =
different
per arch.  %lld has constantly been a printf problem in the past.

/bz

--=20
Bjoern A. Zeeb                                 You have to have visions!
         Stop bit received. Insert coin for new address family.




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?398125AD-ECC7-42EB-8050-BAEC6F444F1C>