Details

    • Type: Bug Bug
    • Status: Closed
    • Severity: Major Major
    • Resolution: Fixed
    • Affects Version/s: 14.2.0
    • Target Release Version/s: 13.15.0, 14.4.0, 15.0.0
    • Component/s: Resources/res_pjsip
    • Security Level: None
    • Labels:
      None
    • Environment:
      linux x64

      Description

      Crash caused by AMI PJSIPShowEndpoint call
      Race condition? Looks like status object is null when calling ast_str_append on line 1252 of res/res_pjsip/pjsip_options.c

      Backtrace excerpt:

      #0  format_contact_status (obj=obj@entry=0x7f6436c41158, arg=arg@entry=0x7f6439c26060, flags=flags@entry=0) at res_pjsip/pjsip_options.c:1252
              wrapper = 0x7f6436c41158
              contact = 0x7f6436bf4528
              ami = 0x7f6439c26060
              status = 0x0
              buf = 0x7f6437de0fa0
              endpoint = 0x7f64378f7428
              __PRETTY_FUNCTION__ = "format_contact_status"
      #1  0x00007f64e4a0f518 in ast_sip_for_each_contact (aor=0x7f643772d5f0, on_contact=0x7f64e49f8ab0 <format_contact_status>, arg=0x7f6439c26060) at res_pjsip/location.c:674
              contact = 0x7f6436bf4528
              wrapper = 0x7f6436c41158
              aor_id = 0x7f6434e8b4b0 "xxxxxxxx"
              contacts = 0x7f64482bba38
              i = {c = 0x7f64482bba38, last_node = 0x7f6436bae668, complete = 0, flags = 0}
              res = 0
              object = 0x7f6436bf4528
              __PRETTY_FUNCTION__ = "ast_sip_for_each_contact"
      

      [Edit by Rusty - removed rest of BT and copied the whole thing to bt_original.txt. Please don't include large chunks of debug in the description field]

      1. bt_original.txt
        2 kB
        Rusty Newton
      2. bt.txt
        48 kB
        Jørgen H
      3. patch.diff
        0.5 kB
        Jørgen H

        Issue Links

          Activity

          Hide
          Jørgen H added a comment -

          fix to problem

          Show
          Jørgen H added a comment - fix to problem
          Hide
          Rusty Newton added a comment -

          Thanks! The next step is to get the patch onto Gerrit. https://wiki.asterisk.org/wiki/display/AST/Git+Usage

          Show
          Rusty Newton added a comment - Thanks! The next step is to get the patch onto Gerrit. https://wiki.asterisk.org/wiki/display/AST/Git+Usage
          Hide
          Friendly Automation added a comment -

          Change 4967 merged by Joshua Colp:
          res_pjsip: Fix crash when contact has no status

          https://gerrit.asterisk.org/4967

          Show
          Friendly Automation added a comment - Change 4967 merged by Joshua Colp: res_pjsip: Fix crash when contact has no status https://gerrit.asterisk.org/4967
          Hide
          Friendly Automation added a comment -

          Change 5096 merged by Joshua Colp:
          res_pjsip: Fix crash when contact has no status

          https://gerrit.asterisk.org/5096

          Show
          Friendly Automation added a comment - Change 5096 merged by Joshua Colp: res_pjsip: Fix crash when contact has no status https://gerrit.asterisk.org/5096
          Hide
          Friendly Automation added a comment -

          Change 5097 merged by zuul:
          res_pjsip: Fix crash when contact has no status

          https://gerrit.asterisk.org/5097

          Show
          Friendly Automation added a comment - Change 5097 merged by zuul: res_pjsip: Fix crash when contact has no status https://gerrit.asterisk.org/5097

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development