jani                                     Sat, 28 Nov 2009 00:38:05 +0000

Revision: http://svn.php.net/viewvc?view=revision&revision=291371

Log:
- Fixed bug #50266 (conflicting types for llabs)

Bug: http://bugs.php.net/50266 (Assigned) conflicting types for llabs
      
Changed paths:
    U   php/php-src/branches/PHP_5_2/NEWS
    U   php/php-src/branches/PHP_5_2/ext/date/config0.m4
    U   php/php-src/branches/PHP_5_2/ext/date/php_date.c
    U   php/php-src/branches/PHP_5_3/NEWS
    U   php/php-src/branches/PHP_5_3/ext/date/config0.m4
    U   php/php-src/branches/PHP_5_3/ext/date/php_date.c
    U   php/php-src/trunk/ext/date/config0.m4
    U   php/php-src/trunk/ext/date/php_date.c

Modified: php/php-src/branches/PHP_5_2/NEWS
===================================================================
--- php/php-src/branches/PHP_5_2/NEWS   2009-11-28 00:35:56 UTC (rev 291370)
+++ php/php-src/branches/PHP_5_2/NEWS   2009-11-28 00:38:05 UTC (rev 291371)
@@ -1,10 +1,13 @@
 PHP                                                                        NEWS
 |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
 ?? Dec 2009, PHP 5.2.12RC4
+- Fixed bug #50266 (conflicting types for llabs). (Jani)

+
 27 Nov 2009, PHP 5.2.12RC3
 - Fixed break in the build chain introduced in 5.2.12RC2 (Jani)

+
 26 Nov 2009, PHP 5.2.12RC2
 - Updated timezone database to version 2009.19 (2009s). (Derick)


Modified: php/php-src/branches/PHP_5_2/ext/date/config0.m4
===================================================================
--- php/php-src/branches/PHP_5_2/ext/date/config0.m4    2009-11-28 00:35:56 UTC 
(rev 291370)
+++ php/php-src/branches/PHP_5_2/ext/date/config0.m4    2009-11-28 00:38:05 UTC 
(rev 291371)
@@ -16,6 +16,8 @@

 PHP_INSTALL_HEADERS([ext/date], [php_date.h lib/timelib.h 
lib/timelib_structs.h lib/timelib_config.h])

+AC_CHECK_FUNCS([llabs])
+
 cat > $ext_builddir/lib/timelib_config.h <<EOF
 #ifdef PHP_WIN32
 # include "config.w32.h"

Modified: php/php-src/branches/PHP_5_2/ext/date/php_date.c
===================================================================
--- php/php-src/branches/PHP_5_2/ext/date/php_date.c    2009-11-28 00:35:56 UTC 
(rev 291370)
+++ php/php-src/branches/PHP_5_2/ext/date/php_date.c    2009-11-28 00:38:05 UTC 
(rev 291371)
@@ -30,16 +30,14 @@
 #include "lib/timelib.h"
 #include <time.h>

-#ifdef PHP_WIN32
+#ifndef HAVE_LLABS
+# ifdef PHP_WIN32
 static __inline __int64 llabs( __int64 i ) { return i >= 0? i: -i; }
-#endif
-
-#if defined(__GNUC__) && __GNUC__ < 3
+# elif defined(__GNUC__) && __GNUC__ < 3
 static __inline __int64_t llabs( __int64_t i ) { return i >= 0 ? i : -i; }
-#endif
-
-#if defined(NETWARE) && defined(__MWERKS__)
+# elif defined(NETWARE) && defined(__MWERKS__)
 static __inline long long llabs( long long i ) { return i >= 0 ? i : -i; }
+# endif
 #endif

 /* {{{ arginfo */

Modified: php/php-src/branches/PHP_5_3/NEWS
===================================================================
--- php/php-src/branches/PHP_5_3/NEWS   2009-11-28 00:35:56 UTC (rev 291370)
+++ php/php-src/branches/PHP_5_3/NEWS   2009-11-28 00:38:05 UTC (rev 291371)
@@ -29,6 +29,7 @@
 - Fixed bug #50282 (xmlrpc_encode_request() changes object into array in
   calling function). (Felipe)
 - Fixed bug #50267 (get_browser(null) does not use HTTP_USER_AGENT). (Jani)
+- Fixed bug #50266 (conflicting types for llabs). (Jani)
 - Fixed bug #50255 (isset() and empty() silently casts array to object).
   (Felipe)
 - Fixed bug #50240 (pdo_mysql.default_socket in php.ini shouldn't used

Modified: php/php-src/branches/PHP_5_3/ext/date/config0.m4
===================================================================
--- php/php-src/branches/PHP_5_3/ext/date/config0.m4    2009-11-28 00:35:56 UTC 
(rev 291370)
+++ php/php-src/branches/PHP_5_3/ext/date/config0.m4    2009-11-28 00:38:05 UTC 
(rev 291371)
@@ -16,6 +16,8 @@

 PHP_INSTALL_HEADERS([ext/date], [php_date.h lib/timelib.h 
lib/timelib_structs.h lib/timelib_config.h])

+AC_CHECK_FUNCS([llabs])
+
 cat > $ext_builddir/lib/timelib_config.h <<EOF
 #ifdef PHP_WIN32
 # include "config.w32.h"

Modified: php/php-src/branches/PHP_5_3/ext/date/php_date.c
===================================================================
--- php/php-src/branches/PHP_5_3/ext/date/php_date.c    2009-11-28 00:35:56 UTC 
(rev 291370)
+++ php/php-src/branches/PHP_5_3/ext/date/php_date.c    2009-11-28 00:38:05 UTC 
(rev 291371)
@@ -35,12 +35,12 @@
 # include "win32/php_stdint.h"
 #endif

-#if defined(__GNUC__) && __GNUC__ < 3
+#ifndef HAVE_LLABS
+# if defined(__GNUC__) && __GNUC__ < 3
 static __inline __int64_t llabs( __int64_t i ) { return i >= 0 ? i : -i; }
-#endif
-
-#if defined(NETWARE) && defined(__MWERKS__)
+# elif defined(NETWARE) && defined(__MWERKS__)
 static __inline long long llabs( long long i ) { return i >= 0 ? i : -i; }
+# endif
 #endif

 /* {{{ arginfo */

Modified: php/php-src/trunk/ext/date/config0.m4
===================================================================
--- php/php-src/trunk/ext/date/config0.m4       2009-11-28 00:35:56 UTC (rev 
291370)
+++ php/php-src/trunk/ext/date/config0.m4       2009-11-28 00:38:05 UTC (rev 
291371)
@@ -16,6 +16,8 @@

 PHP_INSTALL_HEADERS([ext/date], [php_date.h lib/timelib.h 
lib/timelib_structs.h lib/timelib_config.h])

+AC_CHECK_FUNCS([llabs])
+
 cat > $ext_builddir/lib/timelib_config.h <<EOF
 #ifdef PHP_WIN32
 # include "config.w32.h"

Modified: php/php-src/trunk/ext/date/php_date.c
===================================================================
--- php/php-src/trunk/ext/date/php_date.c       2009-11-28 00:35:56 UTC (rev 
291370)
+++ php/php-src/trunk/ext/date/php_date.c       2009-11-28 00:38:05 UTC (rev 
291371)
@@ -36,8 +36,12 @@
 # include "win32/php_stdint.h"
 #endif

-#if defined(NETWARE) && defined(__MWERKS__)
+#ifndef HAVE_LLABS
+# if defined(__GNUC__) && __GNUC__ < 3
+static __inline __int64_t llabs( __int64_t i ) { return i >= 0 ? i : -i; }
+# elif defined(NETWARE) && defined(__MWERKS__)
 static __inline long long llabs( long long i ) { return i >= 0 ? i : -i; }
+# endif
 #endif

 /* {{{ arginfo */

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to