Files
asterisk/channels
David Vossel 3020818583 Merged revisions 292867 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.6.2

................
  r292867 | dvossel | 2010-10-25 14:06:21 -0500 (Mon, 25 Oct 2010) | 32 lines
  
  Merged revisions 292866 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r292866 | dvossel | 2010-10-25 14:05:07 -0500 (Mon, 25 Oct 2010) | 27 lines
    
    This patch turns chan_local pvts into astobj2 objects.
    
    chan_local does some dangerous things involving deadlock avoidance.
    tech_pvt functions like hangup and queue_frame are provided with a
    locked channel upon entry.  Those functions are completely safe as
    long as you don't attempt to give up that channel lock, but that is
    impossible to guarantee due to the required deadlock avoidance necessary
    to lock both the tech_pvt and both channels involved.
    
    In the past, we have tried to account for this by doing things like
    setting a "glare" flag that indicates what function should destroy the
    pvt.  This was used in local_hangup and local_queue_frame to decided
    who should destroy the pvt if they collided in separate threads.  I
    have removed the need to do this by converting all chan_local tech_pvts
    to astobj2.  This means we can ref a pvt before deadlock avoidance
    and not have to worry about that pvt possibly getting destroyed under
    us.  It also cleans up where we destroy the tech_pvt.  The only unlink
    from the tech_pvt container occurs in local_hangup now, which is where
    it should occur.
    
    Since there still may be thread collisions on some functions like
    local_hangup after deadlock avoidance, I have added some checks to detect
    those collisions and exit appropriately.  I think this patch is going to
    solve quite a bit of weirdness we have had with local channels in the past.
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@292868 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-10-25 19:07:50 +00:00
..
2009-08-10 19:20:57 +00:00
2010-07-14 15:48:36 +00:00
2009-08-10 19:20:57 +00:00
2010-06-07 20:04:42 +00:00