]> granicus.if.org Git - transmission/commitdiff
add windows-friendly definitions for PRIu64, PRId64, PRIu32
authorJordan Lee <jordan@transmissionbt.com>
Sat, 24 Aug 2013 20:49:27 +0000 (20:49 +0000)
committerJordan Lee <jordan@transmissionbt.com>
Sat, 24 Aug 2013 20:49:27 +0000 (20:49 +0000)
libtransmission/transmission.h

index 4d3fd82baf1a24cf3d7230c49435b8769ffa1fb8..57f0205348218f817aacb1993cfd861d1afb8ef9 100644 (file)
@@ -55,13 +55,27 @@ extern "C" {
 #endif
 
 #ifndef PRId64
- #define PRId64 "lld"
+ #ifdef WIN32
+  #define PRId64 "I64"
+ #else
+  #define PRId64 "lld"
+ #endif
 #endif
+
 #ifndef PRIu64
- #define PRIu64 "llu"
+ #ifdef WIN32
+  #define PRIu64 "uI64"
+ #else
+  #define PRIu64 "llu"
+ #endif
 #endif
+
 #ifndef PRIu32
- #define PRIu32 "lu"
+ #ifdef WIN32
+  #define PRIu32 "uI32"
+ #else
+  #define PRIu32 "lu"
+ #endif
 #endif
 
 #if defined (WIN32) && defined (_MSC_VER)