cvs: php4 /ext/xslt sablot.c

From: Date: Sat, 02 Nov 2002 15:01:43 +0000
Subject: cvs: php4 /ext/xslt sablot.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-15733@lists.php.net to get a copy of this message
msopacua Sat Nov 2 10:01:43 2002 EDT Modified files: /php4/ext/xslt sablot.c Log: - Use spprintf to avoid two calls to zend_get_executed_filename, suggested by Marcus Börger Index: php4/ext/xslt/sablot.c diff -u php4/ext/xslt/sablot.c:1.66 php4/ext/xslt/sablot.c:1.67 --- php4/ext/xslt/sablot.c:1.66 Sat Nov 2 05:58:01 2002 +++ php4/ext/xslt/sablot.c Sat Nov 2 10:01:42 2002 @@ -19,7 +19,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: sablot.c,v 1.66 2002/11/02 10:58:01 helly Exp $ */ +/* $Id: sablot.c,v 1.67 2002/11/02 15:01:42 msopacua Exp $ */ #ifdef HAVE_CONFIG_H #include "config.h" @@ -554,8 +554,7 @@ /* Since we have args passed, we need to set the base uri, so pull in executor globals and set the base, using the current filename, specifally for the 'arg' scheme */ - baseuri = (char *)emalloc(strlen(zend_get_executed_filename(TSRMLS_C))+7+1); - sprintf(baseuri, "file://%s", zend_get_executed_filename(TSRMLS_C)); + spprintf(&baseuri, 0, "file://%s", zend_get_executed_filename(TSRMLS_C)); SablotSetBaseForScheme(XSLT_PROCESSOR(handle), "arg", baseuri);

« previous php.cvs (#15733) next »