fix 64-bit build

Reported by:	Robert Noland
This commit is contained in:
Luigi Rizzo 2010-04-19 16:35:47 +00:00
parent 6ba1ccc0f2
commit d55ebfbd4e
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=206846

View File

@ -328,9 +328,11 @@ pr_u64(uint64_t *pd, int width)
#else
#define U64_FMT "llu"
#endif
uint64_t d;
uint64_t u;
unsigned long long d;
bcopy (pd, &d, sizeof(d));
bcopy (pd, &u, sizeof(u));
d = u;
return (width > 0) ?
printf("%*" U64_FMT " ", width, d) :
snprintf(NULL, 0, "%" U64_FMT, d) ;