diff options
author | Pavel Janík <paveljanik@apache.org> | 2012-09-27 16:45:09 +0000 |
---|---|---|
committer | Pavel Janík <paveljanik@apache.org> | 2012-09-27 16:45:09 +0000 |
commit | 0452563c1dd321f6cbd70dffb16a8f3df9fbb7e5 (patch) | |
tree | 93f381450daa456142e02912462cde2c8f2f25db /cppu | |
parent | 04f10de02296b9bff1e022daabf0b8ff59234e38 (diff) |
Use proper print format modifier for sizeof() - can be long on some
platforms.
Notes
Notes:
prefer: 57ea40b8b638ebbc8d7b5ade81bed3096c47ee95
Diffstat (limited to 'cppu')
-rw-r--r-- | cppu/source/uno/data.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/cppu/source/uno/data.cxx b/cppu/source/uno/data.cxx index 277ef04ac37e..ee4169b3d333 100644 --- a/cppu/source/uno/data.cxx +++ b/cppu/source/uno/data.cxx @@ -366,7 +366,7 @@ sal_Bool SAL_CALL uno_type_isAssignableFromData( #define BINTEST_VERIFY( c ) \ if (! (c)) { fprintf( stderr, "### binary compatibility test failed: %s [line %d]!!!\n", #c, __LINE__ ); abort(); } #define BINTEST_VERIFYOFFSET( s, m, n ) \ - if (OFFSET_OF(s, m) != n) { fprintf( stderr, "### OFFSET_OF(" #s ", " #m ") = %" SAL_PRI_SIZET "u instead of expected %d!!!\n", OFFSET_OF(s, m), n ); abort(); } + if (OFFSET_OF(s, m) != n) { fprintf( stderr, "### OFFSET_OF(" #s ", " #m ") = %" SAL_PRI_SIZET "u instead of expected %d!!!\n", OFFSET_OF(s, m), static_cast<int>(n) ); abort(); } #if OSL_DEBUG_LEVEL > 1 #if defined(__GNUC__) && (defined(LINUX) || defined(FREEBSD)) && (defined(INTEL) || defined(POWERPC) || defined(X86_64) || defined(S390)) @@ -375,8 +375,8 @@ sal_Bool SAL_CALL uno_type_isAssignableFromData( if (sizeof(s) != n) { fprintf( stderr, "### sizeof(" #s ") = %d instead of expected %d!!!\n", sizeof(s), n ); abort(); } #else // ! GNUC #define BINTEST_VERIFYSIZE( s, n ) \ - fprintf( stderr, "> sizeof(" #s ") = %d\n", sizeof(s) ); \ - if (sizeof(s) != n) { fprintf( stderr, "### sizeof(" #s ") = %d instead of expected %d!!!\n", sizeof(s), n ); abort(); } + fprintf( stderr, "> sizeof(" #s ") = %" SAL_PRI_SIZET "d\n", sizeof(s) ); \ + if (sizeof(s) != n) { fprintf( stderr, "### sizeof(" #s ") = %" SAL_PRI_SIZET "d instead of expected %d!!!\n", sizeof(s), n ); abort(); } #endif #else // ! OSL_DEBUG_LEVEL #define BINTEST_VERIFYSIZE( s, n ) \ |