mirror of
https://github.com/open5gs/open5gs.git
synced 2025-10-22 23:31:57 +00:00
[ipfw2] override errx() to prevent exit on error (#3840)
In ipfw2.c errx() would call exit(), aborting the UPF thread on rule parse errors. Add a macro mapping errx() to ogs_log_message() so errors are logged. We no longer call exit() and the main loop continues on error.
This commit is contained in:
@@ -73,6 +73,10 @@ int resvd_set_number = RESVD_SET;
|
||||
|
||||
int ipfw_socket = -1;
|
||||
|
||||
#if 1 /* modifed by acetcom */
|
||||
#define errx(eval, ...) ogs_log_message(OGS_LOG_ERROR, 0, __VA_ARGS__)
|
||||
#endif
|
||||
|
||||
#define CHECK_LENGTH(v, len) do { \
|
||||
if ((v) < (len)) \
|
||||
errx(EX_DATAERR, "Rule too long"); \
|
||||
|
Reference in New Issue
Block a user