[asterisk-dev] Strange seg fault

LSV basteon at gmail.com
Sun Jan 24 02:26:18 CST 2021


пн, 18 янв. 2021 г. в 21:19, Killian Matter <matter.killian at gmail.com>:

> the function that is executed and get a seg fault is one that reset the
> struct, but none of the calls of this function in the module is used, it's
> really like the audiohook update it's state ( so i suppose from the hang
> up) and then it launch the function i don't know why...
> Maybe on hang up it doesn't have much time to detach audiohook and the
> dialplan goes on so some data are freed before the detach of audiohook and
> datastore do their job and so seg fault.
>
> Killian MATTER
>
>
> Le lun. 18 janv. 2021 à 12:08, Joshua C. Colp <jcolp at digium.com> a écrit :
>
>> On Mon, Jan 18, 2021 at 7:00 AM Killian Matter <matter.killian at gmail.com>
>> wrote:
>>
>>> Hello, i'm working on a module, it has struct that is malloc and free (
>>> a function used in the dialplan to clean everything up). The problem is
>>> that after the clean up a "wild" audiohook update occurs and after that a
>>> custom function from my module is executed and get an seg fault.
>>>
>>
nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn

> it look like a sync problem but is it even possible ? (e didn't ever see a
>>> sync prob in C language)
>>>
>>
>> It is entirely possible for something to be used after it is freed, if
>> care is not taken to ensure it remains valid. Unfortunately there's not
>> really enough information to be able to answer further with any certainty
>> as to what is going on.
>>
>> --
>> Joshua C. Colp
>> Asterisk Technical Lead
>> Sangoma Technologies
>> Check us out at www.sangoma.com and www.asterisk.org
>> --
>> _____________________________________________________________________
>> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>>
>> asterisk-dev mailing list
>> To UNSUBSCRIBE or update options visit:
>>    http://lists.digium.com/mailman/listinfo/asterisk-dev
>
> --
> _____________________________________________________________________
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>
> asterisk-dev mailing list
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20210124/e5747fb4/attachment.html>


More information about the asterisk-dev mailing list