$OpenBSD: patch-Network_Socket_hsc,v 1.6 2015/09/19 07:58:00 kili Exp $

don't throw an error when attempting to setsockopt IPV6_V6ONLY

--- Network/Socket.hsc.orig	Tue Jul  7 20:40:52 2015
+++ Network/Socket.hsc	Tue Sep  1 10:14:57 2015
@@ -318,9 +318,10 @@ socket family stype protocol = do
     withSocketsDo $ return ()
     let sock = MkSocket fd family stype protocol socket_status
 #if HAVE_DECL_IPV6_V6ONLY
-# if defined(mingw32_HOST_OS)
+# if defined(mingw32_HOST_OS) || defined(openbsd_HOST_OS)
     -- the IPv6Only option is only supported on Windows Vista and later,
-    -- so trying to change it might throw an error
+    -- so trying to change it might throw an error. It's also not
+    -- supported on OpenBSD.
     when (family == AF_INET6) $
             E.catch (setSocketOption sock IPv6Only 0) $ (\(_ :: E.IOException) -> return ())
 # else
