[OpenSIPS-Devel] [OpenSIPS/opensips] 3d107a: event_route: fix crash when raising with no params

Răzvan Crainea noreply at github.com
Tue Mar 14 14:59:56 UTC 2023


  Branch: refs/heads/3.2
  Home:   https://github.com/OpenSIPS/opensips
  Commit: 3d107a0a88660db7b6585a58344284901a81d704
      https://github.com/OpenSIPS/opensips/commit/3d107a0a88660db7b6585a58344284901a81d704
  Author: Razvan Crainea <razvan at opensips.org>
  Date:   2023-03-14 (Tue, 14 Mar 2023)

  Changed paths:
    M modules/event_route/route_send.c

  Log Message:
  -----------
  event_route: fix crash when raising with no params

When raising an event using `raise_event` with AVP values that are not
correctly populated, it triggers a corner case in the event_route
module: the module "serializes" the parameters just after the event,
hence, if there is no expanded parameter, the first parameter ends up
pointing to a bogus value, resulting in a crash.

This commit fixes this corner case by treating  it (0 expanded
parameters) just as if there no parameters passed at all.

Many thanks to David Escartin from Sonoc for the help in troubleshooting
this issue!

(cherry picked from commit 7f845994b1ba43f8ffc0c0bdc6c9b8065a935955)





More information about the Devel mailing list