Skip to content

Commit dec3809

Browse files
committed
b2b_logic: Fix a logical bug which could cause crashes
... in b2b_init_request(). Completes c84fe37. Neither @e1 or @e2 can be NULL after the "if" guard, otherwise there is a good chance of a crash shortly afterwards.
1 parent e5f0b5a commit dec3809

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

modules/b2b_logic/logic.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2933,7 +2933,7 @@ str* b2b_process_scenario_init(struct sip_msg* msg, b2bl_cback_f cbf,
29332933
goto error;
29342934
}
29352935

2936-
if (!e1 && !e2) {
2936+
if (!e1 || !e2) {
29372937
LM_ERR("Two bridge entities required!\n");
29382938
goto error;
29392939
}

0 commit comments

Comments
 (0)