From: Eric Leblond Date: Wed, 5 Jun 2019 21:33:17 +0000 (+0200) Subject: af-packet: improve error handling for some hw X-Git-Tag: suricata-5.0.0-rc1~306 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fcae1c18de348762c25cf703de71c3a06009235c;p=thirdparty%2Fsuricata.git af-packet: improve error handling for some hw Some cards seems to return EAGAIN when there is no more place in the hash table. --- diff --git a/src/source-af-packet.c b/src/source-af-packet.c index 496a2a4268..1daa17bdd9 100644 --- a/src/source-af-packet.c +++ b/src/source-af-packet.c @@ -2315,6 +2315,9 @@ static int AFPInsertHalfFlow(int mapd, void *key, uint32_t hash, /* no more place in the hash */ case E2BIG: return 0; + /* no more place in the hash for some hardware bypass */ + case EAGAIN: + return 0; /* if we already have the key then bypass is a success */ case EEXIST: return 1;