summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordevzero2000 <devzero2000>2011-09-05 13:20:54 +0000
committerdevzero2000 <devzero2000>2011-09-05 13:20:54 +0000
commit7bfc5be6d045d8e8fb869308a768a5b683de68a6 (patch)
tree3bc56967cfd3df4dcd8a3ec660ff9ec95af90ac1
parent127a925390d2df065e48c3bd6365c4e7755338a7 (diff)
downloadlibpopt-7bfc5be6d045d8e8fb869308a768a5b683de68a6.tar.gz
redo commit 8396019 againrpm-5_4_3-release
get rid of LONG_LONG format specifier and inline it instead
-rw-r--r--popthelp.c2
-rw-r--r--system.h5
-rw-r--r--test1.c2
3 files changed, 2 insertions, 7 deletions
diff --git a/popthelp.c b/popthelp.c
index eff4f0e..90785a3 100644
--- a/popthelp.c
+++ b/popthelp.c
@@ -266,7 +266,7 @@ assert(le); /* XXX can't happen */
break;
case POPT_ARG_LONGLONG:
#if defined(_MSC_VER) || defined(__MINGW32__)
- le += sprintf(le, "%" LONG_LONG_FORMAT, arg.longlongp[0]);
+ le += sprintf(le, "%I64d", arg.longlongp[0]);
#else
le += sprintf(le, "%lld", arg.longlongp[0]);
#endif
diff --git a/system.h b/system.h
index 72e2b68..bea1fbc 100644
--- a/system.h
+++ b/system.h
@@ -88,10 +88,6 @@ char *alloca ();
#define S_ISGID 00020000
#define S_ISVTX 00010000
-/* I haven't discovered a better way to work around these format
- specifier problems */
-#define LONG_LONG_FORMAT "I64d"
-
/* CHECKME */
#define S_IWGRP 00000020
@@ -147,7 +143,6 @@ static inline int setegid(UNUSED(int x)) { return 1; }
#else
-#define LONG_LONG_FORMAT "lld"
#endif /* defined(_MSC_VER) || defined(__MINGW32__) */
diff --git a/test1.c b/test1.c
index da1fcef..e472cfe 100644
--- a/test1.c
+++ b/test1.c
@@ -335,7 +335,7 @@ int main(int argc, const char ** argv)
fprintf(stdout, " aLong: %ld", aLong);
if (aLongLong != bLongLong)
#if defined(_MSC_VER) || defined(__MINGW32__)
- fprintf(stdout, " aLongLong: %" LONG_LONG_FORMAT, aLongLong);
+ fprintf(stdout, " aLongLong: %I64d", aLongLong);
#else
fprintf(stdout, " aLongLong: %lld", aLongLong);
#endif