summaryrefslogtreecommitdiffstats
path: root/plugins
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2008-12-08 13:31:55 +0100
committerRainer Gerhards <rgerhards@adiscon.com>2008-12-08 13:31:55 +0100
commit128edc1598a13c894fe3853673d1231b9feafc39 (patch)
treea34dfbc9ed94fd0a952f2f8517b256c21196c706 /plugins
parent8b7649fcda9eb15951dcad7728220228b7e29303 (diff)
downloadrsyslog-128edc1598a13c894fe3853673d1231b9feafc39.tar.gz
rsyslog-128edc1598a13c894fe3853673d1231b9feafc39.tar.xz
rsyslog-128edc1598a13c894fe3853673d1231b9feafc39.zip
bugfix: imudp went into an endless loop under some circumstances
(but could also leave it under some other circumstances...) Thanks to David Lang and speedfox for reporting this issue.
Diffstat (limited to 'plugins')
-rw-r--r--plugins/imudp/imudp.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/imudp/imudp.c b/plugins/imudp/imudp.c
index 037da56d..0193ac06 100644
--- a/plugins/imudp/imudp.c
+++ b/plugins/imudp/imudp.c
@@ -297,12 +297,12 @@ CODESTARTrunInput
/* wait for io to become ready */
nfds = select(maxfds+1, (fd_set *) &readfds, NULL, NULL, NULL);
- for (i = 0; nfds && i < *udpLstnSocks; i++) {
- if (FD_ISSET(udpLstnSocks[i+1], &readfds)) {
+ for(i = 0; nfds && i < *udpLstnSocks; i++) {
+ if(FD_ISSET(udpLstnSocks[i+1], &readfds)) {
processSocket(udpLstnSocks[i+1], &frominetPrev, &bIsPermitted,
fromHost, fromHostFQDN, fromHostIP);
- }
--nfds; /* indicate we have processed one descriptor */
+ }
}
/* end of a run, back to loop for next recv() */
}