From 9d0445a7ef5cede771023340dc0b17b3f928d552 Mon Sep 17 00:00:00 2001 From: Vincent Snijders Date: Sat, 14 Jul 2007 13:15:19 +0000 Subject: [PATCH] * fixed checking if file is directory in Erase(File); it was broken if the directory had the FILE_ATTRIBUTE_NOT_CONTENT_INDEXED attribute too git-svn-id: trunk@8049 - --- rtl/win/sysfile.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rtl/win/sysfile.inc b/rtl/win/sysfile.inc index 10e279941a..dfedc6e1a3 100644 --- a/rtl/win/sysfile.inc +++ b/rtl/win/sysfile.inc @@ -53,7 +53,7 @@ begin errno:=GetLastError; if errno=5 then begin - if (GetFileAttributes(p)=FILE_ATTRIBUTE_DIRECTORY) then + if ((GetFileAttributes(p) and FILE_ATTRIBUTE_DIRECTORY)=FILE_ATTRIBUTE_DIRECTORY) then errno:=2; end; Errno2InoutRes;