[asterisk-dev] ast_frfree

Steve Underwood steveu at coppice.org
Tue Sep 26 05:14:49 MST 2006


Hi all,

Apps normally do something like:

    inf = ast_read(chan);
    if (inf == NULL)
        break;
    ... various work with the frame....
    ast_frfree(inf);

and app_rxfax and app_txfax are like this. Since Asterisk 1.2.10 I have 
been receiving complaints of crashes, though my code hasn't changed. 
Someone did a little probing and found ast_read() is sometimes returning 
NULL frames (i.e. type 5), and that when these are freed in ast_frfree 
Asterisk core dumps, because it tries to free a non-existant frame 
buffer. Has there been some change in functionality I should be 
accounting for? It seems like other apps are still doing what I do.

Steve


More information about the asterisk-dev mailing list