mirror of
https://github.com/xmonad/xmonad.git
synced 2025-05-19 08:30:21 -07:00
Merge pull request #428 from a5ob7r/compatible_with_unix_2.8.0
Fix compatibilities with unix 2.8.0.0
This commit is contained in:
commit
cf4d6f31b1
@ -1,3 +1,4 @@
|
||||
{-# LANGUAGE CPP #-}
|
||||
{-# LANGUAGE DeriveTraversable #-}
|
||||
{-# LANGUAGE ExistentialQuantification #-}
|
||||
{-# LANGUAGE FlexibleInstances #-}
|
||||
@ -452,7 +453,11 @@ xfork x = io . forkProcess . finally nullStdin $ do
|
||||
x
|
||||
where
|
||||
nullStdin = do
|
||||
#if MIN_VERSION_unix(2,8,0)
|
||||
fd <- openFd "/dev/null" ReadOnly defaultFileFlags
|
||||
#else
|
||||
fd <- openFd "/dev/null" ReadOnly Nothing defaultFileFlags
|
||||
#endif
|
||||
dupTo fd stdInput
|
||||
closeFd fd
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user