fix warning

This commit is contained in:
Rick V 2019-04-11 11:32:10 -05:00
parent 06be1d88bc
commit d887004d99
No known key found for this signature in database
GPG Key ID: C0EDC8723FDC3465

View File

@ -75,7 +75,9 @@ bencode_write_bytestring(llarp_buffer_t* buff, const void* data, size_t sz)
bool bool
bencode_write_uint64(llarp_buffer_t* buff, uint64_t i) bencode_write_uint64(llarp_buffer_t* buff, uint64_t i)
{ {
#if !defined(__LP64__) || (__APPLE__ && __MACH__) // NetBSDs also do this shit in long mode, wouldn't be surprised
// if all the BSDs do by default
#if !defined(__LP64__) || (__APPLE__ && __MACH__) || (__NetBSD__) || (__OpenBSD__)
if(!buff->writef("i%llu", i)) if(!buff->writef("i%llu", i))
#else #else
if(!buff->writef("i%lu", i)) if(!buff->writef("i%lu", i))