iliaa Mon Jun 9 14:12:36 2003 EDT Added files: /php4/ext/standard/tests/strings bug24098.phpt
Modified files: /php4 NEWS /php4/ext/standard string.c Log: Fixed bug #24098 (Crash in pathinfo() due to double var initialization). # This is a php5 specific bug, no MFB needed Index: php4/NEWS diff -u php4/NEWS:1.1420 php4/NEWS:1.1421 --- php4/NEWS:1.1420 Fri May 30 17:19:56 2003 +++ php4/NEWS Mon Jun 9 14:12:36 2003 @@ -100,6 +100,7 @@ - Fixed is_executable() to be available also on Windows. (Shane) - Fixed dirname() and strip_tags() to be binary-safe. (Moriyoshi) +- Fixed bug #24098 (crash in pathinfo()). (Ilia) - Fixed bug #21985 and #22064 (various mb_send_mail() issues). (Moriyoshi) - Fixed bug #21600 (Assign by reference function call changes variable contents). (Zeev) Index: php4/ext/standard/string.c diff -u php4/ext/standard/string.c:1.387 php4/ext/standard/string.c:1.388 --- php4/ext/standard/string.c:1.387 Mon May 26 20:42:39 2003 +++ php4/ext/standard/string.c Mon Jun 9 14:12:36 2003 @@ -18,7 +18,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: string.c,v 1.387 2003/05/27 00:42:39 msopacua Exp $ */ +/* $Id: string.c,v 1.388 2003/06/09 18:12:36 iliaa Exp $ */ /* Synced with php 3.0 revision 1.193 1999-06-16 [ssb] */ @@ -1268,7 +1268,6 @@ if ((opt & PHP_PATHINFO_EXTENSION) == PHP_PATHINFO_EXTENSION) { char *p; int idx; - int ret_len; int have_basename = ((opt & PHP_PATHINFO_BASENAME) == PHP_PATHINFO_BASENAME); /* Have we alrady looked up the basename? */ Index: php4/ext/standard/tests/strings/bug24098.phpt +++ php4/ext/standard/tests/strings/bug24098.phpt --TEST-- Bug #24098 (pathinfo() crash) --FILE-- <?php var_dump(pathinfo("/dsds.asa")); ?> --EXPECT-- array(3) { ["dirname"]=> string(1) "/" ["basename"]=> string(8) "dsds.asa" ["extension"]=> string(3) "asa" } -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php