mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-04-16 08:49:01 +00:00
remove double event crate, removing a memory leak in valet parking
This commit is contained in:
parent
5a820fdc78
commit
4b07ee5183
@ -805,7 +805,6 @@ static void pres_event_handler(switch_event_t *event)
|
||||
int count = valet_lot_count(lot);
|
||||
|
||||
if (count) {
|
||||
if (switch_event_create(&event, SWITCH_EVENT_PRESENCE_IN) == SWITCH_STATUS_SUCCESS) {
|
||||
if (switch_event_create(&event, SWITCH_EVENT_PRESENCE_IN) == SWITCH_STATUS_SUCCESS) {
|
||||
switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, "proto", VALET_PROTO);
|
||||
switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, "login", lot_name);
|
||||
@ -823,7 +822,6 @@ static void pres_event_handler(switch_event_t *event)
|
||||
switch_event_fire(&event);
|
||||
}
|
||||
found++;
|
||||
}
|
||||
} else {
|
||||
if (switch_event_create(&event, SWITCH_EVENT_PRESENCE_IN) == SWITCH_STATUS_SUCCESS) {
|
||||
switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, "proto", VALET_PROTO);
|
||||
|
Loading…
x
Reference in New Issue
Block a user