[OpenSIPS-Devel] [OpenSIPS/opensips] 769941: siprec: fix dialog callback ref ownership

Răzvan Crainea noreply at github.com
Tue Aug 18 13:59:49 UTC 2026


  Branch: refs/heads/3.6
  Home:   https://github.com/OpenSIPS/opensips
  Commit: 7699415668fc24f5bc5dda8f6583935cb86e978a
      https://github.com/OpenSIPS/opensips/commit/7699415668fc24f5bc5dda8f6583935cb86e978a
  Author: Razvan Crainea <razvan at opensips.org>
  Date:   2026-08-18 (Tue, 18 Aug 2026)

  Changed paths:
    M modules/siprec/siprec_logic.c

  Log Message:
  -----------
  siprec: fix dialog callback ref ownership

Set SIPREC_DLG_CBS when the dialog termination callback takes ownership of the session ref.

Thanks to @kimaiden1984-boop for the report.

Closes #4132

(cherry picked from commit 53fa21afe140283aafc1df5277f7dcd1e898b2ee)


  Commit: 42d83c80007c6b3fccf9d017faa980d4c385cbb4
      https://github.com/OpenSIPS/opensips/commit/42d83c80007c6b3fccf9d017faa980d4c385cbb4
  Author: Yury Kirsanov <yury at kfi.net.au>
  Date:   2026-08-18 (Tue, 18 Aug 2026)

  Changed paths:
    M lib/url.c

  Log Message:
  -----------
  lib/url.c: keep _GNU_SOURCE defined for musl libc builds

url.c defined _GNU_SOURCE only around <stdio.h>/<string.h> and then
undefined it again before including ut.h. On musl libc the feature-test
macros are re-evaluated by every system header, so once _GNU_SOURCE is
removed the later <time.h> (pulled in through ut.h and dprint.h) no
longer exposes clock_gettime(), CLOCK_REALTIME or ctime_r(). The core
then fails to compile on Alpine/musl with gcc 15:

    lib/../mem/../dprint.h:204: implicit declaration of 'ctime_r'
    lib/../ut.h:1401: implicit declaration of 'clock_gettime'
    lib/../ut.h:1401: 'CLOCK_REALTIME' undeclared

glibc is unaffected: it latches internal __USE_* macros at the first
header inclusion, which the later #undef does not clear.

Keep _GNU_SOURCE defined for the whole translation unit, matching how
other core files (io_wait.h, transformations.c) enable it.

(cherry picked from commit 36b28c72bb17d1b11babfabac664d85338b26ef8)


  Commit: cdd0bba75f4f0b2bf04ee01425d95d02c7e7609b
      https://github.com/OpenSIPS/opensips/commit/cdd0bba75f4f0b2bf04ee01425d95d02c7e7609b
  Author: Yury Kirsanov <yury at kfi.net.au>
  Date:   2026-08-18 (Tue, 18 Aug 2026)

  Changed paths:
    M modules/mathops/math_funcs.c
    M modules/mathops/mathops.c

  Log Message:
  -----------
  modules/mathops: keep the feature-test macros defined for musl libc

Both mathops sources define _XOPEN_SOURCE/_GNU_SOURCE for <math.h>, then
undefine them again before including the OpenSIPS headers - the same
pattern lib/url.c had.

musl re-evaluates the feature-test macros in every system header rather
than only on the first one, and its features.h turns on the permissive
default set only when no source macro is defined at all.  Once the block
above has defined them, undefining them leaves the translation unit with
none of them set, so <time.h> stops declaring ctime_r() and dprint.h no
longer compiles:

  Compiling mathops.c
  ../../parser/../dprint.h:204:9: error: implicit declaration of function
      'ctime_r'; did you mean 'ctime'?

Since gcc 14 an implicit declaration is an error, so this is a hard build
failure of the module on Alpine.  Keep the macros defined for the rest of
each file, as lib/url.c now does.

(cherry picked from commit 5abccf465faebaa76405f983d6b54c2d75d8892b)


  Commit: 3350b0204987b30781914dc8e2dd9dd86aa7c234
      https://github.com/OpenSIPS/opensips/commit/3350b0204987b30781914dc8e2dd9dd86aa7c234
  Author: Razvan Crainea <razvan at opensips.org>
  Date:   2026-08-18 (Tue, 18 Aug 2026)

  Changed paths:
    M msg_translator.c

  Log Message:
  -----------
  msg_translator: handle empty multipart bodies

Use a derived zero-length body range when a received body part has no body pointer, keeping multipart reassembly from doing pointer arithmetic on NULL.

Security advisory: ANT-2026-CKSJ0NQF

Security advisory: GHSA-wrjf-686w-4mvp

Thanks to Claude and David Korczynski from Ada Logics for the report.

(cherry picked from commit 8c5c7ba7be79349d72877c59cf5a26e97a747c2c)


Compare: https://github.com/OpenSIPS/opensips/compare/cb67c69b2c16...3350b0204987

To unsubscribe from these emails, change your notification settings at https://github.com/OpenSIPS/opensips/settings/notifications



More information about the Devel mailing list