diff options
author | Pierre Joye <pajoye@php.net> | 2010-02-21 17:44:25 +0000 |
---|---|---|
committer | Pierre Joye <pajoye@php.net> | 2010-02-21 17:44:25 +0000 |
commit | acc6609a2723ccf767c1300b9a8b7eeb07133400 (patch) | |
tree | 720d205a692b648ce4387a043eb44253dfb70d64 | |
parent | dd6ecfc01e25306543670155906627be192c230d (diff) | |
download | php-git-acc6609a2723ccf767c1300b9a8b7eeb07133400.tar.gz |
- get the right error on windows
-rw-r--r-- | main/streams/plain_wrapper.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/main/streams/plain_wrapper.c b/main/streams/plain_wrapper.c index f3722d9fc5..23b9ccbb86 100644 --- a/main/streams/plain_wrapper.c +++ b/main/streams/plain_wrapper.c @@ -866,6 +866,10 @@ static php_stream *php_plain_files_dir_opener(php_stream_wrapper *wrapper, char dir = VCWD_OPENDIR(path); #ifdef PHP_WIN32 + if (!dir) { + php_win32_docref2_from_error(GetLastError(), path, path TSRMLS_CC); + } + if (dir && dir->finished) { closedir(dir); dir = NULL; |