From: Yang Tse Date: Wed, 20 Aug 2008 23:29:07 +0000 (+0000) Subject: Simplify condition check X-Git-Tag: upstream/7.37.1~7386 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1c68e790919cc36331ac5a1e70be5c54f1c6c9d7;p=platform%2Fupstream%2Fcurl.git Simplify condition check --- diff --git a/lib/setup.h b/lib/setup.h index dcd0218..9cf3d8f 100644 --- a/lib/setup.h +++ b/lib/setup.h @@ -135,22 +135,12 @@ Error Compilation_aborted_FORMAT_OFF_TU_already_defined #endif -#if (CURL_SIZEOF_CURL_OFF_T > 4) -# if (CURL_SIZEOF_LONG > 4) -# define FORMAT_OFF_T "ld" -# define FORMAT_OFF_TU "lu" -# else -# define FORMAT_OFF_T "lld" -# define FORMAT_OFF_TU "llu" -# endif +#if (CURL_SIZEOF_CURL_OFF_T > CURL_SIZEOF_LONG) +# define FORMAT_OFF_T "lld" +# define FORMAT_OFF_TU "llu" #else -# if (CURL_SIZEOF_LONG > 2) -# define FORMAT_OFF_T "ld" -# define FORMAT_OFF_TU "lu" -# else -# define FORMAT_OFF_T "lld" -# define FORMAT_OFF_TU "llu" -# endif +# define FORMAT_OFF_T "ld" +# define FORMAT_OFF_TU "lu" #endif /* diff --git a/tests/libtest/lib557.c b/tests/libtest/lib557.c index 1242e6b..c70155e 100644 --- a/tests/libtest/lib557.c +++ b/tests/libtest/lib557.c @@ -18,20 +18,13 @@ int curl_msprintf(char *buffer, const char *format, ...); -#if (CURL_SIZEOF_CURL_OFF_T > 4) -# if (CURL_SIZEOF_LONG > 4) -# define MPRNT_SUFFIX_CURL_OFF_T L -# else -# define MPRNT_SUFFIX_CURL_OFF_T LL -# endif +#if (CURL_SIZEOF_CURL_OFF_T > CURL_SIZEOF_LONG) +# define MPRNT_SUFFIX_CURL_OFF_T LL #else -# if (CURL_SIZEOF_LONG > 2) -# define MPRNT_SUFFIX_CURL_OFF_T L -# else -# define MPRNT_SUFFIX_CURL_OFF_T LL -# endif +# define MPRNT_SUFFIX_CURL_OFF_T L #endif + #ifdef CURL_ISOCPP # define MPRNT_OFF_T_C_HELPER2(Val,Suffix) Val ## Suffix #else