Skip to content

Commit 8ec0a0c

Browse files
committed
Use portable toHandle for openExistingFile too
1 parent cbe0caf commit 8ec0a0c

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

windows/System/File/Platform.hsc

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -105,11 +105,8 @@ openExistingFile fp iomode = bracketOnError
105105
#endif
106106
Nothing)
107107
Win32.closeHandle
108-
toHandle'
108+
(toHandle fp iomode)
109109
where
110-
toHandle' h = do
111-
when (iomode == AppendMode ) $ void $ Win32.setFilePointerEx h 0 Win32.fILE_END
112-
Win32.hANDLEToHandle h
113110
accessMode = case iomode of
114111
ReadMode -> Win32.gENERIC_READ
115112
WriteMode -> Win32.gENERIC_WRITE

0 commit comments

Comments
 (0)