@@ -899,9 +899,12 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
899
899
int bufindex = 0 , isabsolute = 0 ;
900
900
wchar_t * reparsetarget ;
901
901
BOOL isVolume = FALSE;
902
+ #if VIRTUAL_CWD_DEBUG
902
903
char printname [MAX_PATH ];
904
+ int printname_len ;
905
+ #endif
903
906
char substitutename [MAX_PATH ];
904
- int printname_len , substitutename_len ;
907
+ int substitutename_len ;
905
908
int substitutename_off = 0 ;
906
909
907
910
if (++ (* ll ) > LINK_MAX ) {
@@ -928,6 +931,7 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
928
931
929
932
if (pbuffer -> ReparseTag == IO_REPARSE_TAG_SYMLINK ) {
930
933
reparsetarget = pbuffer -> SymbolicLinkReparseBuffer .ReparseTarget ;
934
+ #if VIRTUAL_CWD_DEBUG
931
935
printname_len = pbuffer -> MountPointReparseBuffer .PrintNameLength / sizeof (WCHAR );
932
936
isabsolute = (pbuffer -> SymbolicLinkReparseBuffer .Flags == 0 ) ? 1 : 0 ;
933
937
if (!WideCharToMultiByte (CP_THREAD_ACP , 0 ,
@@ -940,6 +944,7 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
940
944
};
941
945
printname_len = pbuffer -> MountPointReparseBuffer .PrintNameLength / sizeof (WCHAR );
942
946
printname [printname_len ] = 0 ;
947
+ #endif
943
948
944
949
substitutename_len = pbuffer -> MountPointReparseBuffer .SubstituteNameLength / sizeof (WCHAR );
945
950
if (!WideCharToMultiByte (CP_THREAD_ACP , 0 ,
@@ -955,6 +960,7 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
955
960
else if (pbuffer -> ReparseTag == IO_REPARSE_TAG_MOUNT_POINT ) {
956
961
isabsolute = 1 ;
957
962
reparsetarget = pbuffer -> MountPointReparseBuffer .ReparseTarget ;
963
+ #if VIRTUAL_CWD_DEBUG
958
964
printname_len = pbuffer -> MountPointReparseBuffer .PrintNameLength / sizeof (WCHAR );
959
965
if (!WideCharToMultiByte (CP_THREAD_ACP , 0 ,
960
966
reparsetarget + pbuffer -> MountPointReparseBuffer .PrintNameOffset / sizeof (WCHAR ),
@@ -965,6 +971,7 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
965
971
return -1 ;
966
972
};
967
973
printname [pbuffer -> MountPointReparseBuffer .PrintNameLength / sizeof (WCHAR )] = 0 ;
974
+ #endif
968
975
969
976
substitutename_len = pbuffer -> MountPointReparseBuffer .SubstituteNameLength / sizeof (WCHAR );
970
977
if (!WideCharToMultiByte (CP_THREAD_ACP , 0 ,
0 commit comments