diff options
author | Pietro Cerutti <gahr@FreeBSD.org> | 2008-04-16 22:36:42 +0000 |
---|---|---|
committer | Pietro Cerutti <gahr@FreeBSD.org> | 2008-04-16 22:36:42 +0000 |
commit | f5fe51fa725bc203db2338fd2c94d1b18a699c1f (patch) | |
tree | 1da1071ca41695c075df1543bf0037828a9184c0 /net/trickle | |
parent | 07e9c5f2839c380b87b153c4e699e988b8bd1782 (diff) | |
download | ports-f5fe51fa725bc203db2338fd2c94d1b18a699c1f.tar.gz ports-f5fe51fa725bc203db2338fd2c94d1b18a699c1f.zip |
Notes
Diffstat (limited to 'net/trickle')
-rw-r--r-- | net/trickle/Makefile | 3 | ||||
-rw-r--r-- | net/trickle/distinfo | 6 | ||||
-rw-r--r-- | net/trickle/files/patch-trickle-overload.c | 57 |
3 files changed, 49 insertions, 17 deletions
diff --git a/net/trickle/Makefile b/net/trickle/Makefile index 9144d0652620..a8bb7adbaec6 100644 --- a/net/trickle/Makefile +++ b/net/trickle/Makefile @@ -6,8 +6,7 @@ # PORTNAME= trickle -PORTVERSION= 1.06 -PORTREVISION= 8 +PORTVERSION= 1.07 CATEGORIES= net MASTER_SITES= http://monkey.org/~marius/trickle/ diff --git a/net/trickle/distinfo b/net/trickle/distinfo index d28bc3a17d2a..b8d4a33711e3 100644 --- a/net/trickle/distinfo +++ b/net/trickle/distinfo @@ -1,3 +1,3 @@ -MD5 (trickle-1.06.tar.gz) = 8e9b7fcdd49ee8fb94700dd1653f5537 -SHA256 (trickle-1.06.tar.gz) = 9ef83d243d7e91cd5333ef7a497d8fce5aa127d2600ec0b299302f31c37b8609 -SIZE (trickle-1.06.tar.gz) = 166044 +MD5 (trickle-1.07.tar.gz) = 860ebc4abbbd82957c20a28bd9390d7d +SHA256 (trickle-1.07.tar.gz) = 9d36507e0b7afdfb87533244f7d75daa1c17f2768982674f4c9add5ae6c03868 +SIZE (trickle-1.07.tar.gz) = 308863 diff --git a/net/trickle/files/patch-trickle-overload.c b/net/trickle/files/patch-trickle-overload.c index 268b73403a0c..443ef9abd9d7 100644 --- a/net/trickle/files/patch-trickle-overload.c +++ b/net/trickle/files/patch-trickle-overload.c @@ -1,11 +1,19 @@ -/* - * Enable the recv() and send(), I am not sure why it was disabled on FreeBSD - * only but allow other OSs. It works great as I have tested it with a few - * of applications on FreeBSD 6.0. If anyone know why, please let me know. - */ ---- trickle-overload.c.orig Sun May 7 23:05:43 2006 -+++ trickle-overload.c Sun May 7 23:07:06 2006 -@@ -197,15 +197,11 @@ +--- trickle-overload.c.orig 2004-12-13 02:21:53.000000000 +0100 ++++ trickle-overload.c 2008-04-15 21:44:29.000000000 +0200 +@@ -141,8 +141,12 @@ + DECLARE(dup2, int, (int, int)); + + #ifdef HAVE_SENDFILE ++#ifdef __FreeBSD__ ++DECLARE(sendfile, ssize_t, (int, int, off_t, size_t, struct sf_hdtr *, off_t *, int)); ++#else + DECLARE(sendfile, ssize_t, (int, int, off_t *, size_t)); + #endif ++#endif + + static int delay(int, ssize_t *, short); + static struct timeval *getdelay(struct sockdesc *, ssize_t *, short); +@@ -202,15 +206,11 @@ GETADDR(read); GETADDR(readv); @@ -21,7 +29,7 @@ GETADDR(sendto); GETADDR(select); -@@ -627,7 +623,6 @@ +@@ -701,7 +701,6 @@ return (ret); } @@ -29,7 +37,7 @@ ssize_t recv(int sock, void *buf, size_t len, int flags) { -@@ -649,7 +644,6 @@ +@@ -730,7 +729,6 @@ return (ret); } @@ -37,7 +45,7 @@ #ifdef __sun__ ssize_t -@@ -730,7 +724,6 @@ +@@ -832,7 +830,6 @@ return (ret); } @@ -45,7 +53,7 @@ ssize_t send(int sock, const void *buf, size_t len, int flags) { -@@ -752,7 +745,6 @@ +@@ -862,7 +859,6 @@ return (ret); } @@ -53,3 +61,28 @@ ssize_t sendto(int sock, const void *buf, size_t len, int flags, const struct sockaddr *to, +@@ -1005,7 +1001,11 @@ + + #ifdef HAVE_SENDFILE + ssize_t ++#ifdef __FreeBSD__ ++sendfile(int out_fd, int in_fd, off_t offset, size_t count, struct sf_hdtr *hdtr, off_t *sbytes, int flags) ++#else + sendfile(int out_fd, int in_fd, off_t *offset, size_t count) ++#endif + { + size_t inbytes = count, outbytes = count, bytes; + ssize_t ret = 0; +@@ -1021,8 +1021,11 @@ + /* This is a slightly ugly hack. */ + bytes = MIN(inbytes, outbytes); + if (bytes > 0) ++#ifdef __FreeBSD__ ++ ret = (*libc_sendfile)(out_fd, in_fd, offset, bytes, hdtr, sbytes, flags); ++#else + ret = (*libc_sendfile)(out_fd, in_fd, offset, bytes); +- ++#endif + return (ret); + } + #endif /* HAVE_SENDFILE */ |