cvs: php4 /ext/standard string.c

From: Date: Thu, 20 Jul 2000 23:08:26 +0000
Subject: cvs: php4 /ext/standard string.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-825@lists.php.net to get a copy of this message
hholzgra Thu Jul 20 16:08:26 2000 EDT Modified files: /php4/ext/standard string.c Log: fix for bug #5707 Index: php4/ext/standard/string.c diff -u php4/ext/standard/string.c:1.137 php4/ext/standard/string.c:1.138 --- php4/ext/standard/string.c:1.137 Tue Jul 18 13:40:23 2000 +++ php4/ext/standard/string.c Thu Jul 20 16:08:26 2000 @@ -18,7 +18,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: string.c,v 1.137 2000/07/18 20:40:23 zeev Exp $ */ +/* $Id: string.c,v 1.138 2000/07/20 23:08:26 hholzgra Exp $ */ /* Synced with php 3.0 revision 1.193 1999-06-16 [ssb] */ @@ -552,6 +552,8 @@ #endif ) *c='\0'; + else + *str='\0'; } /* {{{ proto string dirname(string path) @@ -567,7 +569,11 @@ convert_to_string_ex(str); ret = estrdup((*str)->value.str.val); php_dirname(ret,(*str)->value.str.len); - RETVAL_STRING(ret,1); + if(*ret) { + RETVAL_STRING(ret,1); + } else { + RETVAL_FALSE; + } efree(ret); } /* }}} */

« previous php.cvs (#825) next »