diff options
Diffstat (limited to 'ext/standard')
| -rw-r--r-- | ext/standard/basic_functions.c | 2 | ||||
| -rw-r--r-- | ext/standard/dir.c | 2 | ||||
| -rw-r--r-- | ext/standard/file.c | 16 | ||||
| -rw-r--r-- | ext/standard/fsock.c | 2 | ||||
| -rw-r--r-- | ext/standard/http_fopen_wrapper.c | 2 | ||||
| -rw-r--r-- | ext/standard/image.c | 2 | ||||
| -rw-r--r-- | ext/standard/md5.c | 2 | ||||
| -rw-r--r-- | ext/standard/proc_open.c | 2 | ||||
| -rw-r--r-- | ext/standard/sha1.c | 2 | ||||
| -rw-r--r-- | ext/standard/streamsfuncs.c | 4 |
10 files changed, 18 insertions, 18 deletions
diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index 3451c26eba..2548a5c045 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -2033,7 +2033,7 @@ PHPAPI int _php_error_log(int opt_err, char *message, char *opt, char *headers T break; case 3: /*save to a file */ - stream = php_stream_open_wrapper(opt, "a", IGNORE_URL | ENFORCE_SAFE_MODE | REPORT_ERRORS, NULL); + stream = php_stream_open_wrapper(opt, "a", IGNORE_URL | REPORT_ERRORS, NULL); if (!stream) return FAILURE; php_stream_write(stream, message, strlen(message)); diff --git a/ext/standard/dir.c b/ext/standard/dir.c index 09a5beb482..dacdbe7234 100644 --- a/ext/standard/dir.c +++ b/ext/standard/dir.c @@ -192,7 +192,7 @@ static void _php_do_opendir(INTERNAL_FUNCTION_PARAMETERS, int createobject) context = php_stream_context_from_zval(zcontext, 0); } - dirp = php_stream_opendir(dirname, ENFORCE_SAFE_MODE|REPORT_ERRORS, context); + dirp = php_stream_opendir(dirname, REPORT_ERRORS, context); if (dirp == NULL) { RETURN_FALSE; diff --git a/ext/standard/file.c b/ext/standard/file.c index 81bd0f2b77..c9bf705a7d 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -379,7 +379,7 @@ PHP_FUNCTION(get_meta_tags) } md.stream = php_stream_open_wrapper(filename, "rb", - (use_include_path ? USE_PATH : 0) | ENFORCE_SAFE_MODE | REPORT_ERRORS, + (use_include_path ? USE_PATH : 0) | REPORT_ERRORS, NULL); if (!md.stream) { @@ -531,7 +531,7 @@ PHP_FUNCTION(file_get_contents) context = php_stream_context_from_zval(zcontext, 0); stream = php_stream_open_wrapper_ex(filename, "rb", - (use_include_path ? USE_PATH : 0) | ENFORCE_SAFE_MODE | REPORT_ERRORS, + (use_include_path ? USE_PATH : 0) | REPORT_ERRORS, NULL, context); if (!stream) { RETURN_FALSE; @@ -592,7 +592,7 @@ PHP_FUNCTION(file_put_contents) mode[1] = 't'; } stream = php_stream_open_wrapper_ex(filename, mode, - ((flags & PHP_FILE_USE_INCLUDE_PATH) ? USE_PATH : 0) | ENFORCE_SAFE_MODE | REPORT_ERRORS, NULL, context); + ((flags & PHP_FILE_USE_INCLUDE_PATH) ? USE_PATH : 0) | REPORT_ERRORS, NULL, context); if (stream == NULL) { RETURN_FALSE; } @@ -751,7 +751,7 @@ PHP_FUNCTION(file) context = php_stream_context_from_zval(zcontext, flags & PHP_FILE_NO_DEFAULT_CONTEXT); - stream = php_stream_open_wrapper_ex(filename, "rb", (use_include_path ? USE_PATH : 0) | ENFORCE_SAFE_MODE | REPORT_ERRORS, NULL, context); + stream = php_stream_open_wrapper_ex(filename, "rb", (use_include_path ? USE_PATH : 0) | REPORT_ERRORS, NULL, context); if (!stream) { RETURN_FALSE; } @@ -893,7 +893,7 @@ PHP_NAMED_FUNCTION(php_if_fopen) context = php_stream_context_from_zval(zcontext, 0); - stream = php_stream_open_wrapper_ex(filename, mode, (use_include_path ? USE_PATH : 0) | ENFORCE_SAFE_MODE | REPORT_ERRORS, NULL, context); + stream = php_stream_open_wrapper_ex(filename, mode, (use_include_path ? USE_PATH : 0) | REPORT_ERRORS, NULL, context); if (stream == NULL) { RETURN_FALSE; } @@ -1491,7 +1491,7 @@ PHP_FUNCTION(readfile) context = php_stream_context_from_zval(zcontext, 0); - stream = php_stream_open_wrapper_ex(filename, "rb", (use_include_path ? USE_PATH : 0) | ENFORCE_SAFE_MODE | REPORT_ERRORS, NULL, context); + stream = php_stream_open_wrapper_ex(filename, "rb", (use_include_path ? USE_PATH : 0) | REPORT_ERRORS, NULL, context); if (stream) { size = php_stream_passthru(stream); php_stream_close(stream); @@ -1612,7 +1612,7 @@ PHP_FUNCTION(unlink) php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s does not allow unlinking", wrapper->wops->label ? wrapper->wops->label : "Wrapper"); RETURN_FALSE; } - RETURN_BOOL(wrapper->wops->unlink(wrapper, filename, ENFORCE_SAFE_MODE | REPORT_ERRORS, context TSRMLS_CC)); + RETURN_BOOL(wrapper->wops->unlink(wrapper, filename, REPORT_ERRORS, context TSRMLS_CC)); } /* }}} */ @@ -1817,7 +1817,7 @@ safe_to_copy: return ret; } - deststream = php_stream_open_wrapper(dest, "wb", ENFORCE_SAFE_MODE | REPORT_ERRORS, NULL); + deststream = php_stream_open_wrapper(dest, "wb", REPORT_ERRORS, NULL); if (srcstream && deststream) { ret = php_stream_copy_to_stream(srcstream, deststream, PHP_STREAM_COPY_ALL) == 0 ? FAILURE : SUCCESS; diff --git a/ext/standard/fsock.c b/ext/standard/fsock.c index b1dce06b48..6970c038a4 100644 --- a/ext/standard/fsock.c +++ b/ext/standard/fsock.c @@ -76,7 +76,7 @@ static void php_fsockopen_stream(INTERNAL_FUNCTION_PARAMETERS, int persistent) ZVAL_STRING(zerrstr, "", 1); } - stream = php_stream_xport_create(hostname, hostname_len, ENFORCE_SAFE_MODE | REPORT_ERRORS, + stream = php_stream_xport_create(hostname, hostname_len, REPORT_ERRORS, STREAM_XPORT_CLIENT | STREAM_XPORT_CONNECT, hashkey, &tv, NULL, &errstr, &err); if (port > 0) { diff --git a/ext/standard/http_fopen_wrapper.c b/ext/standard/http_fopen_wrapper.c index ade1652928..8cd1517bc6 100644 --- a/ext/standard/http_fopen_wrapper.c +++ b/ext/standard/http_fopen_wrapper.c @@ -123,7 +123,7 @@ php_stream *php_stream_url_wrap_http_ex(php_stream_wrapper *wrapper, char *path, Z_TYPE_PP(tmpzval) != IS_STRING || Z_STRLEN_PP(tmpzval) <= 0) { php_url_free(resource); - return php_stream_open_wrapper_ex(path, mode, ENFORCE_SAFE_MODE | REPORT_ERRORS, NULL, context); + return php_stream_open_wrapper_ex(path, mode, REPORT_ERRORS, NULL, context); } /* Called from a non-http wrapper with http proxying requested (i.e. ftp) */ request_fulluri = 1; diff --git a/ext/standard/image.c b/ext/standard/image.c index 8b751deed8..f767d14ba4 100644 --- a/ext/standard/image.c +++ b/ext/standard/image.c @@ -1291,7 +1291,7 @@ PHP_FUNCTION(getimagesize) WRONG_PARAM_COUNT; } - stream = php_stream_open_wrapper(Z_STRVAL_PP(arg1), "rb", STREAM_MUST_SEEK|REPORT_ERRORS|IGNORE_PATH|ENFORCE_SAFE_MODE, NULL); + stream = php_stream_open_wrapper(Z_STRVAL_PP(arg1), "rb", STREAM_MUST_SEEK|REPORT_ERRORS|IGNORE_PATH, NULL); if (!stream) { RETURN_FALSE; diff --git a/ext/standard/md5.c b/ext/standard/md5.c index bf3902484b..add9626200 100644 --- a/ext/standard/md5.c +++ b/ext/standard/md5.c @@ -85,7 +85,7 @@ PHP_NAMED_FUNCTION(php_if_md5_file) return; } - stream = php_stream_open_wrapper(arg, "rb", REPORT_ERRORS | ENFORCE_SAFE_MODE, NULL); + stream = php_stream_open_wrapper(arg, "rb", REPORT_ERRORS, NULL); if (!stream) { RETURN_FALSE; } diff --git a/ext/standard/proc_open.c b/ext/standard/proc_open.c index 6ab5ec44fc..4225cf7329 100644 --- a/ext/standard/proc_open.c +++ b/ext/standard/proc_open.c @@ -660,7 +660,7 @@ PHP_FUNCTION(proc_open) /* try a wrapper */ stream = php_stream_open_wrapper(Z_STRVAL_PP(zfile), Z_STRVAL_PP(zmode), - ENFORCE_SAFE_MODE|REPORT_ERRORS|STREAM_WILL_CAST, NULL); + REPORT_ERRORS|STREAM_WILL_CAST, NULL); /* force into an fd */ if (stream == NULL || FAILURE == php_stream_cast(stream, diff --git a/ext/standard/sha1.c b/ext/standard/sha1.c index 85c85284a2..75295b5c8c 100644 --- a/ext/standard/sha1.c +++ b/ext/standard/sha1.c @@ -85,7 +85,7 @@ PHP_FUNCTION(sha1_file) return; } - stream = php_stream_open_wrapper(arg, "rb", REPORT_ERRORS | ENFORCE_SAFE_MODE, NULL); + stream = php_stream_open_wrapper(arg, "rb", REPORT_ERRORS, NULL); if (!stream) { RETURN_FALSE; } diff --git a/ext/standard/streamsfuncs.c b/ext/standard/streamsfuncs.c index dbbef29632..4dd1dda5be 100644 --- a/ext/standard/streamsfuncs.c +++ b/ext/standard/streamsfuncs.c @@ -116,7 +116,7 @@ PHP_FUNCTION(stream_socket_client) ZVAL_STRING(zerrstr, "", 1); } - stream = php_stream_xport_create(host, host_len, ENFORCE_SAFE_MODE | REPORT_ERRORS, + stream = php_stream_xport_create(host, host_len, REPORT_ERRORS, STREAM_XPORT_CLIENT | (flags & PHP_STREAM_CLIENT_CONNECT ? STREAM_XPORT_CONNECT : 0) | (flags & PHP_STREAM_CLIENT_ASYNC_CONNECT ? STREAM_XPORT_CONNECT_ASYNC : 0), hashkey, &tv, context, &errstr, &err); @@ -190,7 +190,7 @@ PHP_FUNCTION(stream_socket_server) ZVAL_STRING(zerrstr, "", 1); } - stream = php_stream_xport_create(host, host_len, ENFORCE_SAFE_MODE | REPORT_ERRORS, + stream = php_stream_xport_create(host, host_len, REPORT_ERRORS, STREAM_XPORT_SERVER | flags, NULL, NULL, context, &errstr, &err); |
