Skip to content
Snippets Groups Projects
  1. Apr 02, 2021
    • Sean Bright's avatar
      loader.c: Speed up deprecation metadata lookup · 5a13e95c
      Sean Bright authored
      Only use an XPath query once per module, then just navigate the DOM for
      everything else.
      
      Change-Id: Ia0336a7185f9180ccba4b6f631a00f9a22a36e92
      5a13e95c
    • George Joseph's avatar
      res_prometheus: Clone containers before iterating · 53c702e1
      George Joseph authored
      The channels, bridges and endpoints scrape functions were
      grabbing their respective global containers, getting the
      count of entries, allocating metric arrays based on
      that count, then iterating over the container.  If the
      global container had new objects added after the count
      was taken and the metric arrays were allocated, we'd run
      out of metric entries and attempt to write past the end
      of the arrays.
      
      Now each of the scape functions clone their respective
      global containers and all operations are done on the
      clone.  Since the clone is stable between getting the
      count and iterating over it, we can't run past the end
      of the metrics array.
      
      ASTERISK-29130
      Reported-By: Francisco Correia
      Reported-By: BJ Weschke
      Reported-By: Sébastien Duthil
      
      Change-Id: If0c8e40853bc0e9429f2ba9c7f5f358d90c311af
      53c702e1
  2. Apr 01, 2021
    • Joshua C. Colp's avatar
      loader: Output warnings for deprecated modules. · 46ed6af9
      Joshua C. Colp authored
      Using the information from the MODULEINFO XML we can
      now output useful information at the end of module
      loading for deprecated modules. This includes the
      version it was deprecated in, the version it will be
      removed in, and the replacement if available.
      
      ASTERISK-29339
      
      Change-Id: I2080dab97d2186be94c421b41dabf6d79a11611a
      46ed6af9
    • Kevin Harwell's avatar
      res_rtp_asterisk: Fix standard deviation calculation · 0fc906a5
      Kevin Harwell authored
      For some input to the standard deviation algorithm extremely large,
      and wrong numbers were being calculated.
      
      This patch uses a new formula for correctly calculating both the
      running mean and standard deviation for the given inputs.
      
      ASTERISK-29364 #close
      
      Change-Id: Ibc6e18be41c28bed3fde06d612607acc3fbd621f
      0fc906a5
  3. Mar 31, 2021
    • Kevin Harwell's avatar
      res_rtp_asterisk: Don't count 0 as a minimum lost packets · c4a376aa
      Kevin Harwell authored
      The calculated minimum lost packets represents the lowest number of
      lost packets missed during an RTCP report interval. Zero of course
      is the lowest, but the idea is that this value contain the lowest
      number of lost packets once some have been missed.
      
      This patch checks to make sure the number of lost packets over an
      interval is not zero before checking and setting the minimum value.
      
      Also, this patch updates the rtp lost packet test to check for
      packet loss over several reports vs one.
      
      Change-Id: I07d6e21cec61e289c2326138d6bcbcb3c3d5e008
      c4a376aa
    • Kevin Harwell's avatar
      res_rtp_asterisk: Statically declare rtp_drop_packets_data object · 65b68fd0
      Kevin Harwell authored
      This patch makes the drop_packets_data object static.
      
      Change-Id: If4f9b21fa0c47d41a35b6b05941d978efb4da87b
      65b68fd0
    • Joshua C. Colp's avatar
      res_rtp_asterisk: Only raise flash control frame on end. · 8bd13a99
      Joshua C. Colp authored
      Flash in RTP is conveyed the same as DTMF, just with a
      specific digit. In Asterisk however we do flash as a
      single control frame.
      
      This change makes it so that only on end do we provide
      the flash control frame to the core. Previously we would
      provide a flash control frame on both begin and end,
      causing flash to work improperly.
      
      ASTERISK-29373
      
      Change-Id: I1accd9c6e859811336e670e698bd8bd124f33226
      8bd13a99
    • Kevin Harwell's avatar
      res_rtp_asterisk: Add a DEVMODE RTP drop packets CLI command · b86f1ef5
      Kevin Harwell authored
      This patch makes it so when Asterisk is compiled in DEVMODE a CLI
      command is available that allows someone to drop incoming RTP
      packets. The command allows for dropping of packets once, or on a
      timed interval (e.g. drop 10 packets every 5 seconds). A user can
      also specify to drop packets by IP address.
      
      Change-Id: I25fa7ae9bad6ed68e273bbcccf0ee51cae6e7024
      b86f1ef5
    • Joshua C. Colp's avatar
      res_pjsip: Give error when TLS transport configured but not supported. · 623abc2b
      Joshua C. Colp authored
      Change-Id: I058af496021ff870ccec2d8cbade637b348ab80b
      623abc2b
    • Kevin Harwell's avatar
      time: Add timeval create and unit conversion functions · eb92fb72
      Kevin Harwell authored
      Added a TIME_UNIT enumeration, and a function that converts a
      string to one of the enumerated values. Also, added functions
      that create and initialize a timeval object using a specified
      value, and unit type.
      
      Change-Id: Ic31a1c3262a44f77a5ef78bfc85dcf69a8d47392
      eb92fb72
  4. Mar 30, 2021
  5. Mar 28, 2021
  6. Mar 25, 2021
    • Ben Ford's avatar
      logger.conf.sample: Add more debug documentation. · 25758670
      Ben Ford authored
      Change-Id: Iff0e713f2120d8dce8e1e26924b99ed17f9d9dff
      25758670
    • Ben Ford's avatar
      logging: Add .log to samples and update asterisk.logrotate. · 55c53de0
      Ben Ford authored
      Added .log extension to the sample logs in logger.conf.sample so that
      they will be able to be opened in the browser when attached to JIRA
      tickets. Because of this, asterisk.logrotate has also been updated to
      look for .log extensions instead of no extension for log files such as
      full and messages.
      
      Change-Id: I5de743c03f08047d6c6cc80cac5019ae0c4c200f
      55c53de0
    • Sean Bright's avatar
      app_queue.c: Remove dead 'updatecdr' code. · aac442ee
      Sean Bright authored
      Also removed the sample documentation, and some oddly-placed
      documentation about the timeout argument to the Queue() application
      itself. There is a large section on the timeout behavior below.
      
      ASTERISK-26614 #close
      
      Change-Id: I8f84e8304b50305b7c4cba2d9787a5d77c3a6217
      aac442ee
  7. Mar 23, 2021
  8. Mar 22, 2021
    • Mark Murawski's avatar
      logger: Console sessions will now respect logger.conf dateformat= option · b4347c48
      Mark Murawski authored
      The 'core' console (ie: asterisk -c) does read logger.conf and does
      use the dateformat= option.
      
      Whereas 'remote' consoles (ie: asterisk -r -T) does not read logger.conf
      and uses a hard coded dateformat option for printing received verbose messages:
        main/logger.c: static char dateformat[256] = "%b %e %T"
      
      This change will load logger.conf for each remote console session and
      use the dateformat= option to set the per-line timestamp for verbose messages
      
      Change-Id: I3ea10990dbd920e9f7ce8ff771bc65aa7f4ea8c1
      ASTERISK-25358: #close
      Reported-by: Igor Liferenko
      b4347c48
    • Sean Bright's avatar
      app_queue.c: Don't crash when realtime queue name is empty. · 8d3d7bdb
      Sean Bright authored
      ASTERISK-27542 #close
      
      Change-Id: If0b9719380a25533d2aed1053cff845dc3a4854a
      8d3d7bdb
    • George Joseph's avatar
      res_pjsip_session: Make reschedule_reinvite check for NULL topologies · a03a0519
      George Joseph authored
      When the check for equal topologies was added to reschedule_reinvite()
      it was assumed that both the pending and active media states would
      actually have non-NULL topologies.  We since discovered this isn't
      the case.
      
      We now only test for equal topologies if both media states have
      non-NULL topologies.  The logic had to be rearranged a bit to make
      sure that we cloned the media states if their topologies were
      non-NULL but weren't equal.
      
      ASTERISK-29215
      
      Change-Id: I61313cca7fc571144338aac826091791b87b6e17
      a03a0519
    • Joshua C. Colp's avatar
      app_queue: Only send QueueMemberStatus if status changes. · a8a08bcd
      Joshua C. Colp authored
      If a queue member was updated with the same status multiple
      times each time a QueueMemberStatus event would be sent
      which would be a duplicate of the previous.
      
      This change makes it so that the QueueMemberStatus event is
      only sent if the status actually changes.
      
      ASTERISK-29355
      
      Change-Id: I580c60d992a0a8f2bea8b91c868771b3b490d116
      a8a08bcd
    • Joshua C. Colp's avatar
      core_unreal: Fix deadlock with T.38 control frames. · 970b8494
      Joshua C. Colp authored
      When using the ast_unreal_lock_all function no channel
      locks can be held before calling it.
      
      This change unlocks the channel that indicate was
      called on before doing so and then relocks it afterwards.
      
      ASTERISK-29035
      
      Change-Id: Id65016201b5f9c9519a216e250f9101c629e19e9
      970b8494
    • Joshua C. Colp's avatar
      res_pjsip: Add support for partial transport reload. · 71dfbdc7
      Joshua C. Colp authored
      Some configuration items for a transport do not result in
      the underlying transport changing, but instead are just
      state we keep ourselves and use. It is perfectly reasonable
      to change these items.
      
      These include local_net and external_* information.
      
      ASTERISK-29354
      
      Change-Id: I027857ccfe4419f460243e562b5f098434b3d43a
      71dfbdc7
  9. Mar 19, 2021
  10. Mar 17, 2021
    • Joshua C. Colp's avatar
      res_rtp_asterisk: Force resync on SSRC change. · cce5ee5b
      Joshua C. Colp authored
      When an SSRC change occurs the timestamps are likely
      to change as well. As a result we need to reset the
      timestamp mapping done in the calc_rxstamp function
      so that they map properly from timestamp to real
      time.
      
      This previously occurred but due to packet
      retransmission support the explicit setting
      of the marker bit was not effective.
      
      ASTERISK-29352
      
      Change-Id: I2d4c8f93ea24abc1030196706de2d70facf05a5a
      cce5ee5b
    • Joshua C. Colp's avatar
      menuselect: Add ability to set deprecated and removed versions. · efc61a96
      Joshua C. Colp authored
      The "deprecated_in" and "removed_in" information can now be
      set in MODULEINFO for a module and is then displayed in
      menuselect so users can be aware of when a module is slated
      to be deprecated and then removed.
      
      ASTERISK-29337
      
      Change-Id: I6952889cf08e0e9e99cf8b43f99b3cef4688087a
      efc61a96
  11. Mar 16, 2021
  12. Mar 10, 2021
  13. Mar 08, 2021
    • Sean Bright's avatar
      res_musiconhold.c: Plug ref leak caused by ao2_replace() misuse. · df37b818
      Sean Bright authored
      ao2_replace() bumps the reference count of the object that is doing the
      replacing, which is not what we want. We just want to drop the old ref
      on the old object and update the pointer to point to the new object.
      
      Pointed out by George Joseph in #asterisk-dev
      
      Change-Id: Ie8167ed3d4b52b9d1ea2d785f885e8c27206743d
      df37b818
    • Torrey Searle's avatar
      res/res_rtp_asterisk: generate new SSRC on native bridge end · 8c247e2a
      Torrey Searle authored
      For RTCP to work, we update the ssrc to be the one corresponding to
      the native bridge while active.  However when the bridge ends we
      should generate a new SSRC as the sequence numbers will not continue
      from the native bridge left off.
      
      ASTERISK-29300 #close
      
      Change-Id: I23334b6934d2bf6490bda4bbf6414d96b8d17d10
      8c247e2a
  14. Mar 05, 2021
    • Joshua C. Colp's avatar
      sorcery: Add support for more intelligent reloading. · 304f8ddf
      Joshua C. Colp authored
      Some sorcery objects actually contain dynamic content
      that can change despite the underlying configuration
      itself not changing. A good example of this is the
      res_pjsip_endpoint_identifier_ip module which allows
      specifying hostnames. While the configuration may not
      change between reloads the DNS information of the
      hostnames can.
      
      This change adds the ability for a sorcery object to be
      marked as having dynamic contents which is then taken
      into account when reloading by the sorcery file based
      config module. If there is an object with dynamic content
      then a reload will be forced while if there are none
      then the existing behavior of not reloading occurs.
      
      ASTERISK-29321
      
      Change-Id: I9342dc55be46cc00204533c266a68d972760a0b1
      304f8ddf
    • George Joseph's avatar
      res_pjsip_refer: Move the progress dlg release to a serializer · 607603cf
      George Joseph authored
      Although the dlg session count was incremented in a pjsip servant
      thread, there's no guarantee that the last thread to unref this
      progress object was one.  Before we decrement, we need to make
      sure that this is either a servant thread or that we push the
      decrement to a serializer that is one.
      
      Because pjsip_dlg_dec_session requires the dialog lock, we don't
      want to wait on the task to complete if we had to push it to a
      serializer.
      
      Change-Id: I8ff2d5d94be3ff04298394070434e22a7d3cbc41
      607603cf
Loading