af-packet: fix error handling

Only exit from synchronization loop on poll error and not in case
of a timeout.
pull/931/head
Eric Leblond 11 years ago committed by Victor Julien
parent 6e77c4d1b4
commit 43b6cbd4bc

@ -1067,7 +1067,7 @@ static int AFPSynchronizeStart(AFPThreadVars *ptv)
} else if (r == 0 && AFPPeersListStarted()) {
SCLogInfo("Starting to read on %s", ptv->tv->name);
return 1;
} else {
} else if (r < 0) { /* only exit on error */
SCLogWarning(SC_ERR_AFP_READ, "poll failed with retval %d", r);
return 0;
}

Loading…
Cancel
Save