diff --git a/configure.ac b/configure.ac index b2c92692..1c7dc8e1 100644 --- a/configure.ac +++ b/configure.ac @@ -1376,12 +1376,6 @@ AH_BOTTOM([ # include # endif -# ifndef USE_WINSOCK -# define ARG_LL "%ll" -# else -# define ARG_LL "%I64" -# endif - /* detect if we need to cast to unsigned int for FD_SET to avoid warnings */ # ifdef HAVE_WINSOCK2_H # define FD_SET_T (u_int) diff --git a/src/gldns/wire2str.c b/src/gldns/wire2str.c index 2718925e..f6fda2e5 100644 --- a/src/gldns/wire2str.c +++ b/src/gldns/wire2str.c @@ -1059,11 +1059,7 @@ int gldns_wire2str_tsigtime_scan(uint8_t** d, size_t* dl, char** s, size_t* sl) d4 = (*d)[4]; d5 = (*d)[5]; tsigtime = (d0<<40) | (d1<<32) | (d2<<24) | (d3<<16) | (d4<<8) | d5; -#ifndef USE_WINSOCK - w = gldns_str_print(s, sl, "%llu", (long long)tsigtime); -#else - w = gldns_str_print(s, sl, "%I64u", (long long)tsigtime); -#endif + w = gldns_str_print(s, sl, "%"PRIu64, (uint64_t)tsigtime); (*d)+=6; (*dl)-=6; return w; @@ -1746,13 +1742,8 @@ int gldns_wire2str_edns_llq_print(char** s, size_t* sl, uint8_t* data, if(error_code < llq_errors_num) w += gldns_str_print(s, sl, " %s", llq_errors[error_code]); else w += gldns_str_print(s, sl, " error %d", (int)error_code); -#ifndef USE_WINSOCK - w += gldns_str_print(s, sl, " id %llx lease-life %lu", - (unsigned long long)llq_id, (unsigned long)lease_life); -#else - w += gldns_str_print(s, sl, " id %I64x lease-life %lu", - (unsigned long long)llq_id, (unsigned long)lease_life); -#endif + w += gldns_str_print(s, sl, " id %"PRIx64" lease-life %lu", + (uint64_t)llq_id, (unsigned long)lease_life); return w; }