[Home]

Summary:ASTERISK-01992: chan_local does not inherit channel variables or account codes
Reporter:mustdie (mustdie)Labels:
Date Opened:2004-07-12 00:12:10Date Closed:2004-09-25 02:26:23
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Core/General
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) app_dial_accountcode.patch
Description:It looks like chan_local does not inherit variables from originating channel. We are trying to bill customers for call forwarding, and it looks like it is impossible to accomplish with chan_local. 2 CDR records are being generated: First record contains information about incoming call and second record registers dialing to local/number. Everything is great, except that account info is missing for second entry. And we have no way to charge customer for that call.

I've tried dialing local channel with and without '/n' option with same results.
Comments:By: Olle Johansson (oej) 2004-07-12 04:52:48

Check patch 1829 - Transfer of variables to new channel. It may be what you are looking for.

By: mustdie (mustdie) 2004-07-12 08:59:05

I think patch 1829 is not what i'm looking for. If chan Local works as "GoSub" it would be logical to inherit channel variables. (At least account code).
I wrote simple call forwarding application with use of "Local" channel, but i account code goes missing. I have very complex logic in dialplan, that why i'm using Local channel.

By: Mark Spencer (markster) 2004-07-12 09:46:31

I think it's actually a pretty trivial fix.  If you want to find me on IRC I can make the fix and we can confirm that it works.

By: Mark Spencer (markster) 2004-07-12 13:47:08

okay i have a preliminary fix in CVS.  It might do it, if not, you'll need to find me on IRC.

By: mustdie (mustdie) 2004-07-12 20:19:58

Nope, this fix does not work. Still the same behavior. Same missing account code in CDR.

By: Mark Spencer (markster) 2004-07-12 21:15:24

Then find me on IRC and we'll work through it.

By: Olle Johansson (oej) 2004-07-16 14:50:43

Any updates to this bug report? Have you communicated over IRC, if not, try to find each other.

/Housekeeping

By: jjhuff (jjhuff) 2004-07-20 13:05:59

This patch should fix it.  If not, let me know.

By: mustdie (mustdie) 2004-07-20 23:59:06

Patch was tested against most recent CVS and it works just great.
Please merge it into CVS. I also have another request, is any chance you can make 'cdr->userfield' inheritable too?

By: jjhuff (jjhuff) 2004-07-21 16:49:09

Let's merge this patch first.  Then we might consider a better solution for moving vars over a Dial.

By: mustdie (mustdie) 2004-07-21 17:37:31

Agreed

By: Mark Spencer (markster) 2004-07-22 00:10:26

Patch merged in CVS.