[Home]

Summary:ASTERISK-22580: chan_pjsip: crash when attempting to add best codec to channel and no formats are found
Reporter:Private Name (falves11)Labels:
Date Opened:2013-09-24 02:27:01Date Closed:2013-10-30 20:07:41
Priority:MajorRegression?
Status:Closed/CompleteComponents:Channels/chan_pjsip
Versions:12.0.0-alpha1 Frequency of
Occurrence
Related
Issues:
Environment:debian 64Attachments:
Description:Please read, it crashes at the last line
[Sep 24 03:21:56] DEBUG[18280]: pjsip:0 <?>:       tsx0xf9d388 ...State changed from Trying to Proceeding, event=TX_MSG
[Sep 24 03:21:56] DEBUG[18280]: pjsip:0 <?>:       dlg0xf9e1f8 ....Transaction tsx0xf9d388 state changed to Proceeding
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1664 __print_debug_details: Function session_inv_on_state_changed called on event TSX_STATE
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1675 __print_debug_details: The state change pertains to the session with afe8e926-9ceb-4f3c-a93e-ce848e1a8256
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1678 __print_debug_details: The inv session still has an invite_tsx (0xf9d388)
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1687 __print_debug_details: There is no transaction involved in this state change
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1689 __print_debug_details: The current inv state is INCOMING
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1815 session_inv_on_state_changed: Source of transaction state change is TX_MSG
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1770 handle_outgoing: Sending response
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1758 handle_outgoing_response: Method is INVITE, Response is 100 Trying
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1664 __print_debug_details: Function session_inv_on_tsx_state_changed called on event TSX_STATE
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1675 __print_debug_details: The state change pertains to the session with afe8e926-9ceb-4f3c-a93e-ce848e1a8256
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1678 __print_debug_details: The inv session still has an invite_tsx (0xf9d388)
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1683 __print_debug_details: The transaction involved in this state change is 0xf9d388
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1684 __print_debug_details: The current transaction state is Proceeding
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1685 __print_debug_details: The transaction state change event is TX_MSG
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1689 __print_debug_details: The current inv state is INCOMING
[Sep 24 03:21:56] DEBUG[18280]: res_pjsip_session.c:1699 handle_incoming_request: Method is INVITE
[Sep 24 03:21:56] DEBUG[18280]: format_pref.c:339 ast_codec_choose: Could not find preferred codec - Going for the best codec
[Sep 24 03:21:56] WARNING[18280]: channel.c:830 ast_best_codec: Don't know any of (nothing) formats
[Sep 24 03:21:56] ERROR[18280]: astobj2.c:156 INTERNAL_OBJ: user_data is NULL
Comments:By: Rusty Newton (rnewton) 2013-09-25 20:27:34.953-0500

Please read through the guidelines here: https://wiki.asterisk.org/wiki/display/AST/Asterisk+Issue+Guidelines

Please attach a backtrace to this issue (More Actions > Attach Files>
Follow these instructions very closely: https://wiki.asterisk.org/wiki/display/AST/Getting+a+Backtrace

Please attach the full DEBUG log, being sure that res_pjsip__logger.so is loaded to the issue using "Attach Files" as well. https://wiki.asterisk.org/wiki/display/AST/Collecting+Debug+Information







By: Matt Jordan (mjordan) 2013-09-27 08:57:26.855-0500

In particular, the fact there an INVITE request came in with no known formats is ... odd. A pcap along with the backtrace, as well as your {{modules.conf}} would be useful in figuring out what occurred.

By: Private Name (falves11) 2013-10-04 19:27:12.783-0500

I cannot compile asterisk 12 anymore
[LD] chan_console.o -> chan_console.so
  [CC] chan_iax2.c -> chan_iax2.o
  [CC] iax2/firmware.c -> iax2/firmware.o
In file included from iax2/include/firmware.h:27:0,
                from iax2/firmware.c:47:
iax2/include/parser.h:50:22: error: field ‘apparent_addr’ has incomplete type
make[1]: *** [iax2/firmware.o] Error 1
make: *** [channels] Error 2

this is from svn at 8:26 PM EST


By: Richard Mudgett (rmudgett) 2013-10-04 20:37:36.247-0500

Update again.  I just fixed that compile error.

By: Rusty Newton (rnewton) 2013-10-30 09:37:20.800-0500

@Private, are you able to recompile and provide the requested information?

By: Private Name (falves11) 2013-10-30 10:27:34.891-0500

I no longer have access to a box with this version. I was scolded for putting Asterisk 12 in production, and decided to follow the advice given. Also, the channel PJSIP is useless until it updates the channel variables, like the regular SIP channel does, i.e., CHANNEL(recvip), etc. It does not. By the way, the CHANNEL() needs a variable with the inbound peer name, if any, and a flag that says if it is registered or not, since a peer does not need to register.

By: Rusty Newton (rnewton) 2013-10-30 20:07:41.697-0500

Thanks for the response. I'll go ahead and close it out since you and we can't reproduce.