summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorMichael Biebl <biebl@debian.org>2009-10-10 12:29:11 +0200
committerMichael Biebl <biebl@debian.org>2009-10-10 12:29:11 +0200
commitb743785de633f7ff5c39f980496d359e4758ec83 (patch)
treecbb40602f0c84f5fdb911b0bbd3a4b74e49b5211 /plugins
parenta3320fb454a00c23e50fa18b5507b657212b01d2 (diff)
downloadrsyslog-b743785de633f7ff5c39f980496d359e4758ec83.tar.gz
Imported Upstream version 4.4.2upstream/4.4.2
Diffstat (limited to 'plugins')
-rw-r--r--plugins/imudp/imudp.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/plugins/imudp/imudp.c b/plugins/imudp/imudp.c
index 57aec9b..6f4a638 100644
--- a/plugins/imudp/imudp.c
+++ b/plugins/imudp/imudp.c
@@ -178,9 +178,12 @@ processSocket(int fd, struct sockaddr_storage *frominetPrev, int *pbIsPermitted,
ABORT_FINALIZE(RS_RET_ERR);
}
+ if(lenRcvBuf == 0)
+ continue; /* this looks a bit strange, but practice shows it happens... */
+
/* if we reach this point, we had a good receive and can process the packet received */
/* check if we have a different sender than before, if so, we need to query some new values */
- if(memcmp(&frominet, frominetPrev, socklen) != 0) {
+ if(net.CmpHost(&frominet, frominetPrev, socklen) != 0) {
CHKiRet(net.cvthname(&frominet, fromHost, fromHostFQDN, fromHostIP));
memcpy(frominetPrev, &frominet, socklen); /* update cache indicator */
/* Here we check if a host is permitted to send us