Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

network: restore unix stub functions on Windows #489

Merged
merged 1 commit into from
Oct 9, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions Network/Socket.hs
Original file line number Diff line number Diff line change
Expand Up @@ -208,14 +208,12 @@ module Network.Socket
, socketPortSafe
, socketPort

#if !defined(mingw32_HOST_OS)
-- * UNIX-domain socket
, isUnixDomainSocketAvailable
, socketPair
, sendFd
, recvFd
, getPeerCredential
#endif

-- * Name information
, getNameInfo
Expand Down Expand Up @@ -278,9 +276,9 @@ import Network.Socket.Shutdown
import Network.Socket.SockAddr
import Network.Socket.Syscall hiding (connect, bind, accept)
import Network.Socket.Types
import Network.Socket.Unix
#if !defined(mingw32_HOST_OS)
import Network.Socket.Posix.Cmsg
import Network.Socket.Unix
#else
import Network.Socket.Win32.Cmsg
#endif
2 changes: 2 additions & 0 deletions Network/Socket/Unix.hsc
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@ import System.Posix.Types (Fd(..))

import Network.Socket.Buffer
import Network.Socket.Imports
#if !defined(mingw32_HOST_OS)
import Network.Socket.Posix.Cmsg
#endif
import Network.Socket.Types

#if defined(HAVE_GETPEEREID)
Expand Down
2 changes: 1 addition & 1 deletion network.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ library
Network.Socket.SockAddr
Network.Socket.Syscall
Network.Socket.Types
Network.Socket.Unix

build-depends:
base >= 4.9 && < 5,
Expand All @@ -107,7 +108,6 @@ library
Network.Socket.Posix.CmsgHdr
Network.Socket.Posix.IOVec
Network.Socket.Posix.MsgHdr
Network.Socket.Unix

if os(solaris)
extra-libraries: nsl, socket
Expand Down