summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeroen Roovers <jer@gentoo.org>2010-12-27 17:32:24 +0000
committerJeroen Roovers <jer@gentoo.org>2010-12-27 17:32:24 +0000
commit57daa7f6818089ab8021a808bd7f0cc455ddfe64 (patch)
tree19a5e6e5ad6134ded295f16bc37464df665a17f5 /net-analyzer/ethloop/files
parentVersion bump #349871 by Panagiotis Christopoulos. (diff)
downloadhistorical-57daa7f6818089ab8021a808bd7f0cc455ddfe64.tar.gz
historical-57daa7f6818089ab8021a808bd7f0cc455ddfe64.tar.bz2
historical-57daa7f6818089ab8021a808bd7f0cc455ddfe64.zip
Really really really fix recv call (bug #336755).
Package-Manager: portage-2.2.0_alpha10/cvs/Linux i686
Diffstat (limited to 'net-analyzer/ethloop/files')
-rw-r--r--net-analyzer/ethloop/files/ethloop-10-gcc45.patch (renamed from net-analyzer/ethloop/files/ethloop-10-gcc44.patch)11
1 files changed, 7 insertions, 4 deletions
diff --git a/net-analyzer/ethloop/files/ethloop-10-gcc44.patch b/net-analyzer/ethloop/files/ethloop-10-gcc45.patch
index be7f4ddec51a..75b951102245 100644
--- a/net-analyzer/ethloop/files/ethloop-10-gcc44.patch
+++ b/net-analyzer/ethloop/files/ethloop-10-gcc45.patch
@@ -1,7 +1,7 @@
-Fix recv call (bug #336755), add some more includes
+Fix recv call (bug #336755), add some more includes.
--- a/ethloop.c 2002-05-03 15:13:20.000000000 +0200
-+++ b/ethloop.c 2010-12-01 01:51:58.000000000 +0100
++++ b/ethloop.c 2010-12-27 18:21:24.000000000 +0100
@@ -1,5 +1,7 @@
/* vim: cin sw=4 ts=4
*/
@@ -18,12 +18,15 @@ Fix recv call (bug #336755), add some more includes
int sock;
-@@ -133,7 +136,7 @@
+@@ -133,9 +136,9 @@
int recv_raw(int tmo)
{
struct pollfd pf = {sock,POLLIN,0};
- int r; unsigned short proto;
+ ssize_t r; unsigned short proto;
if(poll(&pf,1,tmo) <= 0) return 0;
- r = recv(sock,&buf,1550,0);
+- r = recv(sock,&buf,1550,0);
++ r = recv(sock,&buf,sizeof(buf),0);
if (r <= 0) {
+ printf("error recv (%d)\n",r);
+ return 0;