[asterisk-dev] bug_7506 changes for 1.4, trunk

Steve Murphy murf at digium.com
Tue Nov 7 11:48:40 MST 2006


I'm right at the point of committing the changes I introduced into trunk
and branches/1.4
for bug 7506, and just before typing the commit command, I had to pause
and think.

There are two ways I could do this, and I rushed off and committed
myself to the first
way before taking notice of the structure of the code. 

I think I may have wasted a couple days worth of my (your) time. Maybe
not. You decide.

First of all, the changes I made are **not** evil. But they are not
**minimal**.

The Minimal way to do what I did, would be to leave the channel_alloc
call alone, and
make a new function to simply report the newchannel event, and use this
pretty much 
everywhere the setstate call is being used in the current code. Setstate
would still
be modified to just generate the Newstate report, and nothing else. And
ast_request would
not generate any Newchannel events anymore, either. In other words, the
generation of the Newchannel event does not have to be bound so tightly
to the channel_alloc() call.  The 
side-affects of leaving it as a separate action is that future channel
writers might forget to include the call in their channel code, and
inadvertently generate some bugs that way.

What do my fellow developers want me to do? What's best? Just commit
what I have, and
be done with it, or toss a chunk of it out, and rewrite it? I think I
could have it ready late tomorrow if I do this.

Let me know.

murf

-- 
Steve Murphy
Software Developer
Digium
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3227 bytes
Desc: not available
Url : http://lists.digium.com/pipermail/asterisk-dev/attachments/20061107/deaafc54/smime.bin


More information about the asterisk-dev mailing list