Hi,

In lua I bridge two sessions. When leg B hangup the call I need to set up some custom channel variables for odbc_cdr reporting.

freeswitch.bridge(session1, session2);
session2:execute("set", "custom_var1=asdf");

But when the set command tries to run, the log says "channel is hangup already".

Is there any way to do this properly?

Many thanks,
Zoltan