cvs: php-src(PHP_4_3) / NEWS /ext/standard basic_functions.c math.c php_math.h
| From: | Ilia Alshanetsky | Date: | Mon, 24 May 2004 17:02:32 +0000 |
| Subject: | cvs: php-src(PHP_4_3) / NEWS /ext/standard basic_functions.c math.c php_math.h | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-27430@lists.php.net to get a copy of this message | ||
iliaa Mon May 24 13:02:32 2004 EDT
Modified files: (Branch: PHP_4_3)
/php-src NEWS
/php-src/ext/standard math.c php_math.h basic_functions.c
Log:
MFH: Fixed bug #28508 (Do not make hypot() available if not supported by
libc).
http://cvs.php.net/diff.php/php-src/NEWS?r1=1.1247.2.665&r2=1.1247.2.666&ty=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.1247.2.665 php-src/NEWS:1.1247.2.666
--- php-src/NEWS:1.1247.2.665 Sun May 23 07:05:17 2004
+++ php-src/NEWS Mon May 24 13:02:31 2004
@@ -13,6 +13,8 @@
- Fixed bug #28456 (Problem with enclosed / in uploaded files). (Antony)
- Fixed logic bug in session_register() which allowed registering _SESSION
and/or HTTP_SESSION_VARS. (Sara)
+- Fixed bug #28508 (Do not make hypot() available if not supported by libc).
+ (Ilia)
- Fixed bug #28386 (wordwrap() wraps lines 1 character too soon). (Ilia)
- Fixed bug #28374 (Possible unterminated loop inside
_php_pgsql_trim_message()). (Ilia)
http://cvs.php.net/diff.php/php-src/ext/standard/math.c?r1=1.97.2.10&r2=1.97.2.11&ty=u
Index: php-src/ext/standard/math.c
diff -u php-src/ext/standard/math.c:1.97.2.10 php-src/ext/standard/math.c:1.97.2.11
--- php-src/ext/standard/math.c:1.97.2.10 Fri Apr 30 09:26:06 2004
+++ php-src/ext/standard/math.c Mon May 24 13:02:31 2004
@@ -19,7 +19,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: math.c,v 1.97.2.10 2004/04/30 13:26:06 iliaa Exp $ */
+/* $Id: math.c,v 1.97.2.11 2004/05/24 17:02:31 iliaa Exp $ */
#include "php.h"
#include "php_math.h"
@@ -622,9 +622,9 @@
disappear in the next version of PHP!
*/
+#ifdef HAVE_HYPOT
PHP_FUNCTION(hypot)
{
-#ifdef HAVE_HYPOT
zval **num1, **num2;
if (ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, &num1, &num2) == FAILURE) {
@@ -634,8 +634,8 @@
convert_to_double_ex(num2);
Z_DVAL_P(return_value) = hypot(Z_DVAL_PP(num1), Z_DVAL_PP(num2));
Z_TYPE_P(return_value) = IS_DOUBLE;
-#endif
}
+#endif
/* }}} */
http://cvs.php.net/diff.php/php-src/ext/standard/php_math.h?r1=1.17.2.1&r2=1.17.2.2&ty=u
Index: php-src/ext/standard/php_math.h
diff -u php-src/ext/standard/php_math.h:1.17.2.1 php-src/ext/standard/php_math.h:1.17.2.2
--- php-src/ext/standard/php_math.h:1.17.2.1 Tue Dec 31 11:35:33 2002
+++ php-src/ext/standard/php_math.h Mon May 24 13:02:31 2004
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: php_math.h,v 1.17.2.1 2002/12/31 16:35:33 sebastian Exp $ */
+/* $Id: php_math.h,v 1.17.2.2 2004/05/24 17:02:31 iliaa Exp $ */
#ifndef PHP_MATH_H
#define PHP_MATH_H
@@ -66,7 +66,9 @@
WARNING: these functions are expermental: they could change their names or
disappear in the next version of PHP!
*/
+#ifdef HAVE_HYPOT
PHP_FUNCTION(hypot);
+#endif
PHP_FUNCTION(expm1);
PHP_FUNCTION(log1p);
http://cvs.php.net/diff.php/php-src/ext/standard/basic_functions.c?r1=1.543.2.37&r2=1.543.2.38&ty=u
Index: php-src/ext/standard/basic_functions.c
diff -u php-src/ext/standard/basic_functions.c:1.543.2.37
php-src/ext/standard/basic_functions.c:1.543.2.38
--- php-src/ext/standard/basic_functions.c:1.543.2.37 Mon May 10 03:25:11 2004
+++ php-src/ext/standard/basic_functions.c Mon May 24 13:02:31 2004
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: basic_functions.c,v 1.543.2.37 2004/05/10 07:25:11 helly Exp $ */
+/* $Id: basic_functions.c,v 1.543.2.38 2004/05/24 17:02:31 iliaa Exp $ */
#include "php.h"
#include "php_streams.h"
@@ -494,7 +494,9 @@
PHP_FE(log, NULL)
PHP_FE(log10, NULL)
PHP_FE(sqrt, NULL)
+#ifdef HAVE_HYPOT
PHP_FE(hypot, NULL)
+#endif
PHP_FE(deg2rad, NULL)
PHP_FE(rad2deg, NULL)
PHP_FE(bindec, NULL)