File tree 1 file changed +3
-3
lines changed
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -135,7 +135,7 @@ fileGetCaching :: Fd -> IO Bool
135
135
#if HAVE_O_DIRECT
136
136
fileGetCaching (Fd fd) = do
137
137
r <- throwErrnoIfMinus1 " fileGetCaching" (c_fcntl_read fd # {const F_GETFL })
138
- return ((r .&. opt_val) / = 0 )
138
+ return ((r .&. opt_val) = = 0 )
139
139
where
140
140
opt_val = # {const O_DIRECT }
141
141
#else
@@ -164,8 +164,8 @@ fileSetCaching :: Fd -> Bool -> IO ()
164
164
#if HAVE_O_DIRECT
165
165
fileSetCaching (Fd fd) val = do
166
166
r <- throwErrnoIfMinus1 " fileSetCaching" (c_fcntl_read fd # {const F_GETFL })
167
- let r' | val = fromIntegral r .|. opt_val
168
- | otherwise = fromIntegral r .&. complement opt_val
167
+ let r' | val = fromIntegral r .&. complement opt_val
168
+ | otherwise = fromIntegral r .|. opt_val
169
169
throwErrnoIfMinus1_ " fileSetCaching" (c_fcntl_write fd # {const F_SETFL } r')
170
170
where
171
171
opt_val = # {const O_DIRECT }
You can’t perform that action at this time.
0 commit comments