mpm/ac: use FatalError instead of Critical and exit

pull/8304/head
Victor Julien 2 years ago
parent dcf2f6b2be
commit f33784bed3

@ -310,9 +310,8 @@ static inline void SCACBSEnqueue(StateQueue *q, int32_t state)
q->top = 0;
if (q->top == q->bot) {
SCLogCritical("Just ran out of space in the queue. "
"Fatal Error. Exiting. Please file a bug report on this");
exit(EXIT_FAILURE);
FatalError("Just ran out of space in the queue. "
"Fatal Error. Exiting. Please file a bug report on this");
}
return;
@ -324,9 +323,8 @@ static inline int32_t SCACBSDequeue(StateQueue *q)
q->bot = 0;
if (q->bot == q->top) {
SCLogCritical("StateQueue behaving weirdly. "
"Fatal Error. Exiting. Please file a bug report on this");
exit(EXIT_FAILURE);
FatalError("StateQueue behaving weirdly. "
"Fatal Error. Exiting. Please file a bug report on this");
}
return q->store[q->bot++];
@ -349,9 +347,9 @@ static inline int32_t SCACBSDequeue(StateQueue *q)
(q)->top = 0; \
\
if ((q)->top == (q)->bot) { \
SCLogCritical(SC_ERR_AHO_CORASICK, "Just ran out of space in the queue. " \
"Fatal Error. Exiting. Please file a bug report on this"); \
exit(EXIT_FAILURE); \
FatalError("Just ran out of space in the queue. " \
"Fatal Error. Exiting. Please file a bug report on
this"); \
} \
} while (0)

@ -427,9 +427,8 @@ static inline void SCACTileEnqueue(StateQueue *q, int32_t state)
q->top = 0;
if (q->top == q->bot) {
SCLogCritical("Just ran out of space in the queue. "
"Fatal Error. Exiting. Please file a bug report on this");
exit(EXIT_FAILURE);
FatalError("Just ran out of space in the queue. "
"Fatal Error. Exiting. Please file a bug report on this");
}
}
@ -439,9 +438,8 @@ static inline int32_t SCACTileDequeue(StateQueue *q)
q->bot = 0;
if (q->bot == q->top) {
SCLogCritical("StateQueue behaving weirdly. "
"Fatal Error. Exiting. Please file a bug report on this");
exit(EXIT_FAILURE);
FatalError("StateQueue behaving weirdly. "
"Fatal Error. Exiting. Please file a bug report on this");
}
return q->store[q->bot++];

@ -395,9 +395,7 @@ static inline void SCACEnqueue(StateQueue *q, int32_t state)
q->top = 0;
if (q->top == q->bot) {
SCLogCritical("Just ran out of space in the queue. "
"Fatal Error. Exiting. Please file a bug report on this");
exit(EXIT_FAILURE);
FatalError("Just ran out of space in the queue. Please file a bug report on this");
}
return;
@ -409,9 +407,7 @@ static inline int32_t SCACDequeue(StateQueue *q)
q->bot = 0;
if (q->bot == q->top) {
SCLogCritical("StateQueue behaving weirdly. "
"Fatal Error. Exiting. Please file a bug report on this");
exit(EXIT_FAILURE);
FatalError("StateQueue behaving weirdly. Please file a bug report on this");
}
return q->store[q->bot++];
@ -434,9 +430,9 @@ static inline int32_t SCACDequeue(StateQueue *q)
(q)->top = 0; \
\
if ((q)->top == (q)->bot) { \
SCLogCritical(SC_ERR_AHO_CORASICK, "Just ran out of space in the queue. " \
"Fatal Error. Exiting. Please file a bug report on this"); \
exit(EXIT_FAILURE); \
FatalError("Just ran out of space in the queue. " \
"Fatal Error. Exiting. Please file a bug report on
this"); \
} \
} while (0)

Loading…
Cancel
Save