[asterisk-bugs] [JIRA] (ASTERISK-30258) Dialing API: Cancel a running async thread, does not always cancel all calls

Asterisk Team (JIRA) noreply at issues.asterisk.org
Thu Oct 6 11:30:09 CDT 2022


    [ https://issues.asterisk.org/jira/browse/ASTERISK-30258?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=260405#comment-260405 ] 

Asterisk Team commented on ASTERISK-30258:
------------------------------------------

Thanks for creating a report! The issue has entered the triage process. That means the issue will wait in this status until a Bug Marshal has an opportunity to review the issue. Once the issue has been reviewed you will receive comments regarding the next steps towards resolution. Please note that log messages and other files should not be sent to the Sangoma Asterisk Team unless explicitly asked for. All files should be placed on this issue in a sanitized fashion as needed.

A good first step is for you to review the [Asterisk Issue Guidelines|https://wiki.asterisk.org/wiki/display/AST/Asterisk+Issue+Guidelines] if you haven't already. The guidelines detail what is expected from an Asterisk issue report.

Then, if you are submitting a patch, please review the [Patch Contribution Process|https://wiki.asterisk.org/wiki/display/AST/Patch+Contribution+Process].

Please note that once your issue enters an open state it has been accepted. As Asterisk is an open source project there is no guarantee or timeframe on when your issue will be looked into. If you need expedient resolution you will need to find and pay a suitable developer. Asking for an update on your issue will not yield any progress on it and will not result in a response. All updates are posted to the issue when they occur.

Please note that by submitting data, code, or documentation to Sangoma through JIRA, you accept the Terms of Use present at [https://www.asterisk.org/terms-of-use/|https://www.asterisk.org/terms-of-use/].

> Dialing API: Cancel a running async thread, does not always cancel all calls
> ----------------------------------------------------------------------------
>
>                 Key: ASTERISK-30258
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-30258
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Core/Dial
>    Affects Versions: 18.8.0
>            Reporter: Frederic LE FOLL
>
> A race condition may occur in ast_dial_join() function (Dialing API: Cancel async thread), if caller cancels its call while a called party has just answered but has not yet started running its application.
> This was detected with Page() application, calling approx 20 called parties with auto-answer, and caller almost immediately canceling its call (e.g. within 10 to 50 milliseconds).
> Called party that has answered just before caller hangup:
> - has not yet the is_running_app flag up, thus ast_dial_join() does not do Soft Hangup,
> - but has left the waitfor loop, thus pthread_kill() does not have the expected effect.
> Observation: when this race condition occurs for Page application, then :
> - called parties (with one ast_dial_run() per called party) do not get cancelled, they start executing the application (ConfBridge for Page) and never get kicked out, because caller never got connected to ConfBridge,
> - caller Channel gets stuck in ast_dial_join() because pthread_join(thread, NULL) never ends, except if all called called devices hangup.
> This was seen with Asterisk 18.6 but it should be reproductible with other versions, since ast_dial_join() has not changed in recent versions.



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list