On Wednesday, 29 April 2015, at 1:26 am, Tanguy Pruvot wrote:
> For this case i generally cast the param to the biggest possible type.
> 
> printf("llu", (uint64_t) val);

You probably shouldn't assume that uint64_t is the largest possible integer 
type. In particular, off_t is not guaranteed to be <= 64 bits.

#include <inttypes.h>
printf("%"PRIuMAX, (uintmax_t) val);

But I hate the idea of involving all the nasty large-integer arithmetic 
machinery if it's not strictly necessary.
_______________________________________________
busybox mailing list
busybox@busybox.net
http://lists.busybox.net/mailman/listinfo/busybox

Reply via email to