[asterisk-dev] 0017234: [patch] Memory leak in manager.c - eqe should never be null!

Dave Woolley david.woolley at bts.co.uk
Mon Jun 7 12:22:36 CDT 2010


I don't believe the latest fix to issues 0017234
<https://issues.asterisk.org/view.php?id=17234> can have addressed the
fundamental cause of the actual crash.  That's because it is defending
against a condition that should be impossible.  session->last_ev is,
currently, always set non-null before the session is added to the
sessions list and should never be allowed to go null again once it is on
that list.  The purge_sessions function, picks it from the sessions
list, so should never receive a null last_ev pointer, so it looks to me
that suppressing the use count decrement when it is null is simply
papering over cracks.

I can't work out how last_ev could get null.

Unless I can understand why it gets null, I can't be sure that the same
problem won't occur for TCP AMI, and if it can, know how to test that it
is fixed for our usage. 

As this is a public list, please ignore the confidentiality part of the
following.
-- 
David Woolley
BTS Holdings Plc
Tel: +44 (0)20 8401 9000 Fax: +44 (0)20 8401 9100
http://www.bts.co.uk 


This email and its attachments may be confidential and are intended solely for the use of the individual to whom it is addressed. Any views or opinions expressed are solely those of the author and do not necessarily represent those of the company. If you are not the intended recipient of this email, you must take no action based upon it, nor must you copy or show it to anyone. Please contact the sender if you believe you have received this email in error. In accordance with English Law, email communications may be monitored. All reasonable precautions have been taken to ensure that no viruses are present in this email; however, the company cannot accept responsibility for loss or damage arising from the use of this email. We recommend that you subject this email to your own virus checking procedures. BTS Holdings PLC is registered in England 1517630, VAT No 523 5092 66. Registered office, BTS House, Manor Road, Wallington, SM6 0DD


More information about the asterisk-dev mailing list