Fix weird compile error

remotes/origin/master-1.0.x
Victor Julien 17 years ago
parent b1531f7244
commit df4c642c70

@ -1,15 +1,12 @@
/* Copyright (c) 2008 Victor Julien <victor@inliniac.net> */
#ifndef __ACTION_GLOBALS_H__
#define __ACTION_GLOBALS_H__
/* Changing them as flags, so later we can have alerts
* and drop simultaneously */
#define ACTION_ALERT 0x01
#define ACTION_DROP 0x02
#define ACTION_REJECT 0x04
#define ACTION_REJECT_DST 0x08
#define ACTION_REJECT_BOTH 0x10
#define ACTION_PASS 0x20
#define ACTION_ALERT 0x01
#define ACTION_DROP 0x02
#define ACTION_REJECT 0x04
#define ACTION_REJECT_DST 0x08
#define ACTION_REJECT_BOTH 0x10
#define ACTION_PASS 0x20
#endif /* __ACTION_GLOBALS_H__ */

@ -408,21 +408,15 @@ void NFQSetVerdict(NFQThreadVars *t, Packet *p) {
//printf("%p verdicting on queue %" PRIu32 "\n", t, t->queue_num);
if (p->action & ACTION_REJECT || p->action & ACTION_REJECT_BOTH ||
p->action & ACTION_REJECT_DST || p->action & ACTION_DROP) {
p->action & ACTION_REJECT_DST || p->action & ACTION_DROP) {
verdict = NF_DROP;
#ifdef COUNTERS
t->dropped++;
#endif /* COUNTERS */
} else if (p->action & ACTION_ALERT || p->action & ACTION_ALERT) {
} else {
verdict = NF_ACCEPT;
#ifdef COUNTERS
t->accepted++;
#endif /* COUNTERS */
} else {
/* a verdict we don't know about, drop to be sure */
verdict = NF_DROP;
#ifdef COUNTERS
t->dropped++;
#endif /* COUNTERS */
}

Loading…
Cancel
Save