aboutsummaryrefslogtreecommitdiff
path: root/www/hs-http-server
diff options
context:
space:
mode:
authorGabor Pali <pgj@FreeBSD.org>2012-06-03 20:52:29 +0000
committerGabor Pali <pgj@FreeBSD.org>2012-06-03 20:52:29 +0000
commit46e9ab0ca5e504d3509678b4d43a41d938650e75 (patch)
treea34afe36b374e7894e236fb8cee020928d36c967 /www/hs-http-server
parentbe44ec14c77de91f8ac86e25372545e0e39e9bcb (diff)
downloadports-46e9ab0ca5e504d3509678b4d43a41d938650e75.tar.gz
ports-46e9ab0ca5e504d3509678b4d43a41d938650e75.zip
Notes
Diffstat (limited to 'www/hs-http-server')
-rw-r--r--www/hs-http-server/Makefile2
-rw-r--r--www/hs-http-server/files/patch-Network__HTTP__Server.hs13
-rw-r--r--www/hs-http-server/files/patch-Network__HTTP__Server__Utils.hs18
3 files changed, 32 insertions, 1 deletions
diff --git a/www/hs-http-server/Makefile b/www/hs-http-server/Makefile
index 77ed28c69664..e3c61e122722 100644
--- a/www/hs-http-server/Makefile
+++ b/www/hs-http-server/Makefile
@@ -7,7 +7,7 @@
PORTNAME= http-server
PORTVERSION= 1
-PORTREVISION= 3
+PORTREVISION= 4
CATEGORIES= www haskell
MAINTAINER= haskell@FreeBSD.org
diff --git a/www/hs-http-server/files/patch-Network__HTTP__Server.hs b/www/hs-http-server/files/patch-Network__HTTP__Server.hs
new file mode 100644
index 000000000000..0c736fa6a37d
--- /dev/null
+++ b/www/hs-http-server/files/patch-Network__HTTP__Server.hs
@@ -0,0 +1,13 @@
+--- ./Network/HTTP/Server.hs.orig 2009-06-13 03:58:45.000000000 +0200
++++ ./Network/HTTP/Server.hs 2012-05-13 21:03:32.137467690 +0200
+@@ -123,8 +123,9 @@
+
+ client sock addr =
+ do let name = ppSockAddr addr ""
++ let port = ppSockPort addr
+ logInfo lg 0 ("Accepted connection from " ++ name)
+- conn <- socketConnection name sock -- XXX: name?
++ conn <- socketConnection name port sock -- XXX: name?
+ setStreamHooks conn nullHooks { hook_close =
+ logInfo lg 0 ("Closing connection to " ++ ppSockAddr addr "")
+ }
diff --git a/www/hs-http-server/files/patch-Network__HTTP__Server__Utils.hs b/www/hs-http-server/files/patch-Network__HTTP__Server__Utils.hs
new file mode 100644
index 000000000000..d816ca0cf2f9
--- /dev/null
+++ b/www/hs-http-server/files/patch-Network__HTTP__Server__Utils.hs
@@ -0,0 +1,18 @@
+--- ./Network/HTTP/Server/Utils.hs.orig 2009-06-13 03:58:45.000000000 +0200
++++ ./Network/HTTP/Server/Utils.hs 2012-05-13 21:03:02.570464902 +0200
+@@ -48,11 +48,11 @@
+
+ ppSockAddr :: SockAddr -> ShowS
+ ppSockAddr (SockAddrInet port addr) = ppHostAddress addr
+- . showChar ':' . shows port
+ #ifdef _OS_UNIX
+-ppSockAddr (SockAddrInet6 port _ addr _) =
+- ppHostAddress6 addr . showChar ':' . shows port
++ppSockAddr (SockAddrInet6 port _ addr _) = ppHostAddress6 addr
+ ppSockAddr (SockAddrUnix sock) = showString "unix/" . showString sock
+ #endif
+
+-
++ppSockPort :: SockAddr -> Int
++ppSockPort (SockAddrInet port _) = fromIntegral port
++ppSockPort (SockAddrInet6 port _ _ _) = fromIntegral port