diff options
author | Dmitry Stogov <dmitry@zend.com> | 2015-03-04 02:05:28 +0300 |
---|---|---|
committer | Dmitry Stogov <dmitry@zend.com> | 2015-03-04 02:05:28 +0300 |
commit | 2fa8d67a5ce59ba9ba6192481e3c2522c3ff5542 (patch) | |
tree | 9d9d57215f756c387722e74d7d1e1c2de3276a1c /main/php_streams.h | |
parent | 2841aa95db84f3563c94c90f84bf7f47ba159a2d (diff) | |
download | php-git-2fa8d67a5ce59ba9ba6192481e3c2522c3ff5542.tar.gz |
Use zend_string* instead of char* for opened_patch handling. Avoid reallocations and improve string reuse.
Diffstat (limited to 'main/php_streams.h')
-rw-r--r-- | main/php_streams.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/main/php_streams.h b/main/php_streams.h index 3cd0c047cd..3035bd560b 100644 --- a/main/php_streams.h +++ b/main/php_streams.h @@ -134,7 +134,7 @@ typedef struct _php_stream_ops { typedef struct _php_stream_wrapper_ops { /* open/create a wrapped stream */ php_stream *(*stream_opener)(php_stream_wrapper *wrapper, const char *filename, const char *mode, - int options, char **opened_path, php_stream_context *context STREAMS_DC); + int options, zend_string **opened_path, php_stream_context *context STREAMS_DC); /* close/destroy a wrapped stream */ int (*stream_closer)(php_stream_wrapper *wrapper, php_stream *stream); /* stat a wrapped stream */ @@ -143,7 +143,7 @@ typedef struct _php_stream_wrapper_ops { int (*url_stat)(php_stream_wrapper *wrapper, const char *url, int flags, php_stream_statbuf *ssb, php_stream_context *context); /* open a "directory" stream */ php_stream *(*dir_opener)(php_stream_wrapper *wrapper, const char *filename, const char *mode, - int options, char **opened_path, php_stream_context *context STREAMS_DC); + int options, zend_string **opened_path, php_stream_context *context STREAMS_DC); const char *label; @@ -554,7 +554,7 @@ PHPAPI int php_register_url_stream_wrapper(const char *protocol, php_stream_wrap PHPAPI int php_unregister_url_stream_wrapper(const char *protocol); PHPAPI int php_register_url_stream_wrapper_volatile(const char *protocol, php_stream_wrapper *wrapper); PHPAPI int php_unregister_url_stream_wrapper_volatile(const char *protocol); -PHPAPI php_stream *_php_stream_open_wrapper_ex(const char *path, const char *mode, int options, char **opened_path, php_stream_context *context STREAMS_DC); +PHPAPI php_stream *_php_stream_open_wrapper_ex(const char *path, const char *mode, int options, zend_string **opened_path, php_stream_context *context STREAMS_DC); PHPAPI php_stream_wrapper *php_stream_locate_url_wrapper(const char *path, const char **path_for_open, int options); PHPAPI const char *php_stream_locate_eol(php_stream *stream, zend_string *buf); |