Lines Matching refs:wrapper
151 static zend_llist *php_get_wrapper_errors_list(php_stream_wrapper *wrapper TSRMLS_DC) in php_get_wrapper_errors_list()
157 zend_hash_find(FG(wrapper_errors), (const char*)&wrapper, in php_get_wrapper_errors_list()
158 sizeof wrapper, (void**)&list); in php_get_wrapper_errors_list()
164 void php_stream_display_wrapper_errors(php_stream_wrapper *wrapper, const char *path, const char *c… in php_stream_display_wrapper_errors() argument
170 if (wrapper) { in php_stream_display_wrapper_errors()
171 zend_llist *err_list = php_get_wrapper_errors_list(wrapper TSRMLS_CC); in php_stream_display_wrapper_errors()
210 if (wrapper == &php_plain_files_wrapper) { in php_stream_display_wrapper_errors()
228 void php_stream_tidy_wrapper_error_log(php_stream_wrapper *wrapper TSRMLS_DC) in php_stream_tidy_wrapper_error_log()
230 if (wrapper && FG(wrapper_errors)) { in php_stream_tidy_wrapper_error_log()
231 zend_hash_del(FG(wrapper_errors), (const char*)&wrapper, sizeof wrapper); in php_stream_tidy_wrapper_error_log()
240 PHPAPI void php_stream_wrapper_log_error(php_stream_wrapper *wrapper, int options TSRMLS_DC, const … in php_stream_wrapper_log_error() argument
249 if (options & REPORT_ERRORS || wrapper == NULL) { in php_stream_wrapper_log_error()
259 zend_hash_find(FG(wrapper_errors), (const char*)&wrapper, in php_stream_wrapper_log_error()
260 sizeof wrapper, (void**)&list); in php_stream_wrapper_log_error()
266 zend_hash_update(FG(wrapper_errors), (const char*)&wrapper, in php_stream_wrapper_log_error()
267 sizeof wrapper, &new_list, sizeof new_list, (void**)&list); in php_stream_wrapper_log_error()
439 if (stream->wrapper && stream->wrapper->wops && stream->wrapper->wops->stream_closer) { in _php_stream_free()
440 stream->wrapper->wops->stream_closer(stream->wrapper, stream TSRMLS_CC); in _php_stream_free()
441 stream->wrapper = NULL; in _php_stream_free()
691 if (stream->wrapper != &php_plain_files_wrapper) { in _php_stream_read()
757 if (stream->wrapper && stream->wrapper->wops->stream_stat != NULL) { in _php_stream_stat()
758 return stream->wrapper->wops->stream_stat(stream->wrapper, stream, ssb TSRMLS_CC); in _php_stream_stat()
1631 PHPAPI int php_register_url_stream_wrapper(char *protocol, php_stream_wrapper *wrapper TSRMLS_DC) in php_register_url_stream_wrapper()
1639 …d_hash_add(&url_stream_wrappers_hash, protocol, protocol_len + 1, &wrapper, sizeof(wrapper), NULL); in php_register_url_stream_wrapper()
1657 PHPAPI int php_register_url_stream_wrapper_volatile(char *protocol, php_stream_wrapper *wrapper TSR… in php_register_url_stream_wrapper_volatile()
1669 …return zend_hash_add(FG(stream_wrappers), protocol, protocol_len + 1, &wrapper, sizeof(wrapper), N… in php_register_url_stream_wrapper_volatile()
1820 php_stream_wrapper *wrapper = NULL; local
1822 wrapper = php_stream_locate_url_wrapper(path, NULL, ENFORCE_SAFE_MODE TSRMLS_CC);
1823 if (!wrapper || !wrapper->wops || !wrapper->wops->stream_mkdir) {
1827 return wrapper->wops->stream_mkdir(wrapper, path, mode, options, context TSRMLS_CC);
1835 php_stream_wrapper *wrapper = NULL; local
1837 wrapper = php_stream_locate_url_wrapper(path, NULL, ENFORCE_SAFE_MODE TSRMLS_CC);
1838 if (!wrapper || !wrapper->wops || !wrapper->wops->stream_rmdir) {
1842 return wrapper->wops->stream_rmdir(wrapper, path, options, context TSRMLS_CC);
1849 php_stream_wrapper *wrapper = NULL; local
1866 wrapper = php_stream_locate_url_wrapper(path, &path_to_open, ENFORCE_SAFE_MODE TSRMLS_CC);
1867 if (wrapper && wrapper->wops->url_stat) {
1868 ret = wrapper->wops->url_stat(wrapper, path_to_open, flags, ssb, context TSRMLS_CC);
1896 php_stream_wrapper *wrapper = NULL; local
1905 wrapper = php_stream_locate_url_wrapper(path, &path_to_open, options TSRMLS_CC);
1907 if (wrapper && wrapper->wops->dir_opener) {
1908 stream = wrapper->wops->dir_opener(wrapper,
1913 stream->wrapper = wrapper;
1916 } else if (wrapper) {
1917 php_stream_wrapper_log_error(wrapper, options ^ REPORT_ERRORS TSRMLS_CC, "not implemented");
1920 php_stream_display_wrapper_errors(wrapper, path, "failed to open dir" TSRMLS_CC);
1922 php_stream_tidy_wrapper_error_log(wrapper TSRMLS_CC);
1945 php_stream_wrapper *wrapper = NULL; local
1973 wrapper = php_stream_locate_url_wrapper(path, &path_to_open, options TSRMLS_CC);
1974 if (options & STREAM_USE_URL && (!wrapper || !wrapper->is_url)) {
1982 if (wrapper) {
1983 if (!wrapper->wops->stream_opener) {
1984 php_stream_wrapper_log_error(wrapper, options ^ REPORT_ERRORS TSRMLS_CC,
1987 stream = wrapper->wops->stream_opener(wrapper,
1995 php_stream_wrapper_log_error(wrapper, options ^ REPORT_ERRORS TSRMLS_CC,
2002 stream->wrapper = wrapper;
2067 php_stream_display_wrapper_errors(wrapper, path, "failed to open stream" TSRMLS_CC);
2073 php_stream_tidy_wrapper_error_log(wrapper TSRMLS_CC);