Skip to content

Commit 5b5130c

Browse files
committed
Revert "backport 51e1da6 into 7.0"
This reverts commit 8da8756.
1 parent 536b3ca commit 5b5130c

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

Zend/zend_virtual_cwd.c

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -899,12 +899,9 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
899899
int bufindex = 0, isabsolute = 0;
900900
wchar_t * reparsetarget;
901901
BOOL isVolume = FALSE;
902-
#if VIRTUAL_CWD_DEBUG
903902
char printname[MAX_PATH];
904-
int printname_len;
905-
#endif
906903
char substitutename[MAX_PATH];
907-
int substitutename_len;
904+
int printname_len, substitutename_len;
908905
int substitutename_off = 0;
909906

910907
if(++(*ll) > LINK_MAX) {
@@ -931,7 +928,6 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
931928

932929
if(pbuffer->ReparseTag == IO_REPARSE_TAG_SYMLINK) {
933930
reparsetarget = pbuffer->SymbolicLinkReparseBuffer.ReparseTarget;
934-
#if VIRTUAL_CWD_DEBUG
935931
printname_len = pbuffer->MountPointReparseBuffer.PrintNameLength / sizeof(WCHAR);
936932
isabsolute = (pbuffer->SymbolicLinkReparseBuffer.Flags == 0) ? 1 : 0;
937933
if (!WideCharToMultiByte(CP_THREAD_ACP, 0,
@@ -944,7 +940,6 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
944940
};
945941
printname_len = pbuffer->MountPointReparseBuffer.PrintNameLength / sizeof(WCHAR);
946942
printname[printname_len] = 0;
947-
#endif
948943

949944
substitutename_len = pbuffer->MountPointReparseBuffer.SubstituteNameLength / sizeof(WCHAR);
950945
if (!WideCharToMultiByte(CP_THREAD_ACP, 0,
@@ -960,7 +955,6 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
960955
else if(pbuffer->ReparseTag == IO_REPARSE_TAG_MOUNT_POINT) {
961956
isabsolute = 1;
962957
reparsetarget = pbuffer->MountPointReparseBuffer.ReparseTarget;
963-
#if VIRTUAL_CWD_DEBUG
964958
printname_len = pbuffer->MountPointReparseBuffer.PrintNameLength / sizeof(WCHAR);
965959
if (!WideCharToMultiByte(CP_THREAD_ACP, 0,
966960
reparsetarget + pbuffer->MountPointReparseBuffer.PrintNameOffset / sizeof(WCHAR),
@@ -971,7 +965,6 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
971965
return -1;
972966
};
973967
printname[pbuffer->MountPointReparseBuffer.PrintNameLength / sizeof(WCHAR)] = 0;
974-
#endif
975968

976969
substitutename_len = pbuffer->MountPointReparseBuffer.SubstituteNameLength / sizeof(WCHAR);
977970
if (!WideCharToMultiByte(CP_THREAD_ACP, 0,

0 commit comments

Comments
 (0)