Sergey Safarov writes:
s = 0xef41e788a0679800 <error: Cannot access memory at address
0xef41e788a0679800> len = -1685145520
you can check https://github.com/kamailio/kamailio/issues/2788 https://github.com/kamailio/kamailio/issues/2736
Here changed memory handling You can try the current master or manually apply commits with fix
I don't think these two crashes are related. My config doe not use substdef's.
-- Juha