With multiple media subscriptions, codec handlers are called
consecutively, once for each forwarding chain, leading to DTMF events
reported multiple times. The DTMF trigger must therefore keep track of
the state in the upper media object, not in the codec handlers.
Change-Id: I9ceaf406e093f25b7c037a325a0f2a7a91954922
If there's no config file present then retrieval of the table number
yields an empty string. Allow this as an expected case to silence a
warning from bash (using -lt against an empty string)
Change-Id: I0420d2e1c555f6b56a56fc5f47d3bc183a929e50
* pkg/deb/debian should be the only source
* pkg/deb/debian/backports: scripts to generate differences
This way is quite easy to maintain different versions, the
differences are managed via scripts
Change-Id: I0ac3a35fe3facf005564141563e2fb11b73cbefc
Some functions (packet_dtmf in particular) called from the sequencer
depend on upper-level locking, so make sure this happens even if we're
bypassing the sequencer and do passthrough.
Change-Id: I6c729c3ba8075736fd614b8c06e3415b9c9e5ca7
For this initial version, these are mostly copies of the existing
/debian tree, with `ngcp-rtpengine` renamed to `rtpengine`, added
"conflicts" with the `ngcp-rtpengine` packages, and NGCP-specific
"suggests" removed.
Change-Id: I64289f9907ec09d003a96b8ac81f83c79d413747
The aliases created by systemd under Install/Alias are created and
removed as the service is enabled and disabled, and don't serve as
generic alias names. Furthermore they seem to linger behind when the
package is removed or replaced, which leads to collisions and
installation failures when the NGCP-specific package is replaced by the
non-NGCP version.
Change-Id: I2313ffffb1fa4fb1d570b23113b0618744c58e26
This package name is not used anywhere as a dependency, therefore it
makes no sense to list as a "provides"
Change-Id: I20db5308328b1c911495bf31417e4996a9824c3c
SSRC entries might be present for the same SSRC in multiple contexts,
but only one of them will hold the actual stats. Don't create output
SSRC entries unless we know they won't be empty, as otherwise we won't
be able to create the actual SSRC entries (with stats) later on as they
dict key will already exist.
Change-Id: I54e263a17e14869ebb98456963f8ca75d11e9a89
This is useful because we log to stderr, which technically would allow
unlimited log line length, but this is in fact turned over to syslog,
which truncates log lines that are too long.
Change-Id: Iee8994842335ab1cf94941c14eced01e29120bc9
Not only check for the presence of a sink, but also check for a sink FD.
Treat a sink without an FD as if there is no sink.
Closes#1401
Change-Id: I04c0be33f8cae39399674ca0a87185a729daa843
Flag a socket with an error strike when packets are received too fast,
and refuse processing once too many strikes have occurred. This should
prevent forwarding loops from taking down the system.
Change-Id: Idc574f2f1dbbcb156efc37a80e903dc4e60ef1b1
libcs are implementing changes to fix the year 2038 issue on 32 bit
platforms (see [1]). musl libc already went ahead and implemented it,
starting with musl-1.2.0 (see [2]).
This commit adds a new definition to lib/loglib.h:
TIME_T_INT_FMT
If __USE_TIME_BITS64 is defined (by a time64 libc, see [1]), it's set to
the proper conversions for type int64_t, PRId64. If __USE_TIME_BITS64 is
not defined, the status quo remains unchanged ("%ld" is used).
The new definition is used in the different parts of rtpengine, where
appropriate.
Note: Richard confirmed that the "%u" format in daemon/cdr.c is not
needed, so this gets swept under the rug.
These changes get rid of the new warnings that appeared with musl-1.2.0.
Below an example warning:
In file included from ./log.h:6,
from ../include/obj.h:94,
from ../include/media_socket.h:9,
from ../include/call.h:26,
from ../include/redis.h:15,
from redis.c:1:
redis.c: In function 'redis_check_conn':
../lib/loglib.h:56:30: warning: format '%ld' expects argument of type 'long int', but argument 5 has type 'time_t' {aka 'long long int'} [-Wformat=]
56 | __ilog(prio, "[%s] " fmt, log_level_names[system], ##__VA_ARGS__); \
| ^~~~~~~
../lib/loglib.h:64:39: note: in expansion of macro 'ilogsn'
64 | #define ilogs(system, prio, fmt, ...) ilogsn(log_level_index_ ## system, prio, fmt, ##__VA_ARGS__)
| ^~~~~~
../lib/loglib.h:63:30: note: in expansion of macro 'ilogs'
63 | #define ilog(prio, fmt, ...) ilogs(core, prio, fmt, ##__VA_ARGS__)
| ^~~~~
redis.c:887:17: note: in expansion of macro 'ilog'
887 | ilog(LOG_WARNING, "Redis server %s is disabled. Don't try RE-Establishing for %ld more seconds",
| ^~~~
[1] https://sourceware.org/glibc/wiki/Y2038ProofnessDesign
[2] https://musl.libc.org/time64.html
Signed-off-by: Sebastian Kemper <sebastian_ml@gmx.net>