From: Dmitry Stogov Date: Tue, 23 Jan 2007 17:03:59 +0000 (+0000) Subject: Fixed wrong realpath() result for unexistent files on win32 X-Git-Tag: RELEASE_1_0_0RC1~145 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=4fbcbccf4f5801560d5e4379fd46c3710f7f8f0d;p=php Fixed wrong realpath() result for unexistent files on win32 --- diff --git a/TSRM/tsrm_virtual_cwd.c b/TSRM/tsrm_virtual_cwd.c index 0c7dc6d3f4..d91f8ff609 100644 --- a/TSRM/tsrm_virtual_cwd.c +++ b/TSRM/tsrm_virtual_cwd.c @@ -647,6 +647,11 @@ no_realpath: memcpy(&state->cwd[state->cwd_length], data.cFileName, length+1); ptr_length = length; FindClose(hFind); + } else if (use_realpath == CWD_REALPATH) { + free(free_path); + CWD_STATE_FREE(state); + *state = old_state; + return 1; } } #endif