diff options
author | John Marino <marino@FreeBSD.org> | 2016-10-10 15:58:40 +0000 |
---|---|---|
committer | John Marino <marino@FreeBSD.org> | 2016-10-10 15:58:40 +0000 |
commit | 37dd64c7bb67ffbe2f611a4a5a6fe94ff3eba2ce (patch) | |
tree | d29741ffbf79f67fe493b330da10f190aac95b39 /net/anet | |
parent | bb91d541e6f4f4ae83b67393efa9b24a2906e177 (diff) |
Notes
Diffstat (limited to 'net/anet')
-rw-r--r-- | net/anet/Makefile | 5 | ||||
-rw-r--r-- | net/anet/distinfo | 6 | ||||
-rw-r--r-- | net/anet/files/patch-add-TCP_NODELAY | 59 |
3 files changed, 5 insertions, 65 deletions
diff --git a/net/anet/Makefile b/net/anet/Makefile index 08aa286146a5..4354309dfdc5 100644 --- a/net/anet/Makefile +++ b/net/anet/Makefile @@ -2,8 +2,7 @@ # $FreeBSD$ PORTNAME= anet -PORTVERSION= 0.3.3 -PORTREVISION= 1 +PORTVERSION= 0.3.4 CATEGORIES= net MASTER_SITES= http://www.codelabs.ch/download/ DISTNAME= libanet-${PORTVERSION} @@ -21,7 +20,7 @@ MAKE_ARGS+= NUM_CPUS=${MAKE_JOBS_NUMBER} \ OS=bsd OPTIONS_DEFINE= TEST DOCS -TEST_DESC= Run unit test suite before installation +TEST_DESC= Run unit test suite before installation TEST_ALL_TARGET= tests TEST_BUILD_DEPENDS= ${LOCALBASE}/lib/gnat/ahven.gpr:devel/ahven DOCS_USES= gmake diff --git a/net/anet/distinfo b/net/anet/distinfo index cd63444100b3..391649a1c907 100644 --- a/net/anet/distinfo +++ b/net/anet/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1467439601 -SHA256 (libanet-0.3.3.tar.bz2) = 8ef101d47f549232b0276687235ac7767a2b50b6bde5f48ca21c20007e8ad20b -SIZE (libanet-0.3.3.tar.bz2) = 50553 +TIMESTAMP = 1476093104 +SHA256 (libanet-0.3.4.tar.bz2) = 7462a5530fe0b8ff9dbf20a2f0a2dd0bf55e7f0c322bc10f9f0327f971706e07 +SIZE (libanet-0.3.4.tar.bz2) = 50996 diff --git a/net/anet/files/patch-add-TCP_NODELAY b/net/anet/files/patch-add-TCP_NODELAY deleted file mode 100644 index 8257ff5dc77a..000000000000 --- a/net/anet/files/patch-add-TCP_NODELAY +++ /dev/null @@ -1,59 +0,0 @@ ---- src/anet-constants.ads.orig 2016-06-29 10:26:01 UTC -+++ src/anet-constants.ads -@@ -45,6 +45,7 @@ package Anet.Constants is - -- Protocol levels -- - --------------------- - -+ IPPROTO_TCP : constant := 6; -- TCP - IPPROTO_IPV6 : constant := 41; -- IPv6 - IPPROTO_ESP : constant := 50; -- ESP - ---- src/bsd/anet-os_constants.ads.orig 2016-06-29 10:26:01 UTC -+++ src/bsd/anet-os_constants.ads -@@ -26,5 +26,6 @@ package Anet.OS_Constants is - IPV6_ADD_MEMBERSHIP : constant := 12; -- Join multicast group (IPv6) - - O_NONBLOCK : constant := 4; -- Non-blocking sockets -+ TCP_NODELAY : constant := 1; -- Don't delay send to coalesce pkts - - end Anet.OS_Constants; ---- src/anet-sockets.ads.orig 2016-06-29 10:26:01 UTC -+++ src/anet-sockets.ads -@@ -119,6 +119,12 @@ package Anet.Sockets is - Value : String); - -- Set socket option of given socket to specified string value. - -+ procedure Set_Socket_Send_Delay -+ (Socket : Socket_Type; -+ Without_Delay : Boolean); -+ -- Set Nagle's Algorithm (socket may delay sending data) -+ -- By default, sockets have the algorithm enabled and can delay sending -+ - private - - use type Interfaces.C.int; ---- src/anet-sockets.adb.orig 2016-06-29 10:26:01 UTC -+++ src/anet-sockets.adb -@@ -279,4 +279,22 @@ package body Anet.Sockets is - Value & "'"); - end Set_Socket_Option; - -+ ------------------------------------------------------------------------- -+ -+ procedure Set_Socket_Send_Delay -+ (Socket : Socket_Type; -+ Without_Delay : Boolean) -+ is -+ Val : C.int := C.int (Boolean'Pos (Without_Delay)); -+ begin -+ Errno.Check_Or_Raise -+ (Result => Thin.C_Setsockopt -+ (S => Socket.Sock_FD, -+ Level => Constants.Sys.IPPROTO_TCP, -+ Optname => OS_Constants.TCP_NODELAY, -+ Optval => Val'Address, -+ Optlen => Val'Size / 8), -+ Message => "Unable to set socket option TCP_NODELAY"); -+ end Set_Socket_Send_Delay; -+ - end Anet.Sockets; |