Don't treat the `force_inc_sdp_ver` flag as
the `replace_sdp_version` one, but consider
it as a separate option flag.
Correct usage of it accordingly.
Additionally: change sdp_version_check() func signature
to use `force_increase` as bool.
Change-Id: I9ed772a5a3535d887dda5a5a116b6326c8f5f46a
Use str_cmp() to implement str_eq()
Use str_shift_cmp() in place of str_prefix()
Update return types to bool
Change-Id: If7927d957e20780408e77da1d04baffa082a6914
This should give slightly better performance due to not having to look
for the terminator byte twice. Not benchmarked. No-op.
Change-Id: I458a06b492393fcf5b186a61b69acabdf63a216e
Obsolete str_init(), rename STR_INIT() to just STR(), and replace all
instances of str_init() with STR().
no-op
Change-Id: I981529063ad2ea26089add467f7a84b638dbf423
These helper functions were largely unused or inconsistently used.
Create a new type and streamline usage.
Change-Id: I5cd9756a26994d027dd4ff6a2d01a8c6c3cffe30
`delete-delay` is already parsed using bencode_dictionary_get_int_str()
so we don't need to special-handle string type values
Change-Id: If9758ccfbbe18674b7731aa53b9de5bd3fd87ae4
The function in charge of processing codec flags can already handle
standalone string values and doesn't require a list to wrap single
strings.
Change-Id: Id9bc97d455c75a3d1b0a19c5dbe43f677c937401
Allocate sdp_origin members using `str_init_dup_str()`
which uses g_malloc, so that when freeing the sdp_origin
structure later in `sdp_orig_free()` it doesn't inadvertently
lead to the seg fault.
Otherwise if any member isn't recovered (e.g. username)
it remains pointing to NULL with 0 len, which will be gracefully
handled in `str_free_dup()`.
Change-Id: I131f0096103052445754cc01ac5072776e957cda
While processing subscriptions in `monologue_subscribe_request()`
update the `->session_last_sdp_orig` related to the dest monologue.
This can be then later used in the `sdp_create()` the user
of which is `call_subscribe_request_ng()`.
Change-Id: Iee503ca94f82e0e5334fcd787f984f1ed3f7ca4d
Add support of replacements flags:
- replace-origin
- replace-origin-username
- replace-origin-full
Additionally: fix websocket tests, because now
the `-` symbol isn't considered as the one to be
set always when using `replce-origin-full`.
Instead it will use values of the very first parsed SDP.
Change-Id: I7636f020cb92cb760fcd25b0b84509e6d5ba2a9f
Set the `monologue->session_last_sdp_orig` not while
replacing in `sdp_replace()`, but while initializing the
monologue in `__call_monologue_init_from_flags()`.
This allows to be agnostic in relation to `sdp_replace()`,
and let the `monologue->session_last_sdp_orig` be always
actual for the `sdp_create()` related processing
(without a need to pull the SDP sessions list towards it).
Change-Id: Ideb129ab8a94ef750abfa222335aede42bcbcc89
The option flag `replace-origin-full` should replace whole
origin (o=) line of the SDP body, so that all origin fields
in the `o=` line always remain the same in all SDPs going to a
particular RTP endpoint.
So, not just a straight-forward replacing with own values.
A behavior in relation to the address field is the same
as by the `origin` option flag.
Correct according tests and add one more.
Change-Id: I4bcb740db5cd68a75fb754f5f6b5d21e19b05e1b