diff options
author | Ondřej Surý <ondrej@sury.org> | 2011-02-16 10:13:02 +0100 |
---|---|---|
committer | Ondřej Surý <ondrej@sury.org> | 2011-02-16 10:13:02 +0100 |
commit | fd5a0b31640419ca63d1ddeaffd6d3cf2a741814 (patch) | |
tree | bfd17d84c5181d7b98d7d66f56573f4fc897e31c /ext/xsl/xsltprocessor.c | |
parent | 01fcdff3849c3691d9aaeaab735846ab6d8895ca (diff) | |
download | php-fd5a0b31640419ca63d1ddeaffd6d3cf2a741814.tar.gz |
Imported Upstream version 5.3.5upstream/5.3.5
Diffstat (limited to 'ext/xsl/xsltprocessor.c')
-rw-r--r-- | ext/xsl/xsltprocessor.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/ext/xsl/xsltprocessor.c b/ext/xsl/xsltprocessor.c index e6d7e5333..531c8d309 100644 --- a/ext/xsl/xsltprocessor.c +++ b/ext/xsl/xsltprocessor.c @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: xsltprocessor.c 293036 2010-01-03 09:23:27Z sebastian $ */ +/* $Id: xsltprocessor.c 305507 2010-11-18 15:22:22Z pajoye $ */ #ifdef HAVE_CONFIG_H #include "config.h" @@ -642,6 +642,9 @@ PHP_FUNCTION(xsl_xsltprocessor_transform_to_uri) ret = -1; if (newdocp) { + if (strlen(uri) != uri_len) { + RETURN_FALSE; + } ret = xsltSaveResultToFilename(uri, newdocp, sheetp, 0); xmlFreeDoc(newdocp); } @@ -845,7 +848,7 @@ PHP_FUNCTION(xsl_xsltprocessor_set_profiling) if (intern->profiling) { efree(intern->profiling); } - if (filename != NULL) { + if (filename != NULL && strlen(filename) == filename_len) { intern->profiling = estrndup(filename,filename_len); } else { intern->profiling = NULL; |