Skip to content

Commit

Permalink
Only report mkdir() errors if error reporting option is set.
Browse files Browse the repository at this point in the history
  • Loading branch information
Ilia Alshanetsky committed Jan 17, 2006
1 parent 694042e commit 5f9dde2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion main/streams/plain_wrapper.c
Original file line number Diff line number Diff line change
Expand Up @@ -1120,7 +1120,9 @@ static int php_plain_files_mkdir(php_stream_wrapper *wrapper, char *dir, int mod
if (*p == '\0' && *(p + 1) != '\0') {
*p = DEFAULT_SLASH;
if ((ret = VCWD_MKDIR(buf, (mode_t)mode)) < 0) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s", strerror(errno));
if (options & REPORT_ERRORS) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s", strerror(errno));
}
break;
}
}
Expand Down

0 comments on commit 5f9dde2

Please sign in to comment.