The GLib slice allocator has been obsoleted. Having a mixture of two
allocators can lead to hidden issues on systems that use different
implementations. Take the leap and replace everything with g_new/g_free.
Change-Id: I025c8383ef47b2c2472573360407fd6a6ca339b3
Special codec handler to support not forwarding (nor any processing
whatsoever) of particular payload types at all. Support this in the
kernel module as well.
Change-Id: If10227affa54307e1e9b448eadd0bf2bfc5774ba
Only use the codec handler's "kernelize" flag to determine whether a
particular payload type can be handled by the kernel or not. It's
supposed to be a reliable indicator, making checking the other flags
unnecessary.
Change-Id: I5fe58eded55ea973ed555e4376ee8200f112d162
Split function into one part handling the "target" (i.e. ingress)
portion of the forwarding chain, and one function handling just the
outputs.
Change-Id: I3766da3c4bc5caee4eb6bae8978f177a83cc231a
First step to refactoring the kernelize* functions. Keep all state in a
central struct that is passed to all functions. Requires an auxiliary
bool to facilitate a case distinction in kernelize_one, which can be
removed once refactoring is complete.
Change-Id: I5de8404d55d5b320ef5cb8cd27d5b684802fa7e7
This seems to be an acceptable and reliable way to detect RTCP
multiplexed with RTP, even if `a=rtcp-mux` wasn't advertised in the SDP.
Take the opportunity to clean up __streams_set_sinks() a bit by giving
the variables better names.
Change-Id: I0cdc5e4a544641591fc2aabca12fb11bab3453f7
Separate out the two distinct use cases of requesting a specific port,
and requesting (one or more) random ports.
Change-Id: Ifbe7725d8638d49f620c9f4b9445342d180c8770
Add helper functions wrapping around reserve_port which directly return
a socket_port_link object. This allows us to rework
__get_consecutive_ports and release_reserved_port to eliminate mixing
different port numbers in the same list, which makes for cleaner code.
Change-Id: Ia9808f71c854f6efd0e93ce8df4527c4aea311bd
Turns out that g_ptr_array_new_full or g_ptr_array_new_sized only
preallocates array members, but doesn't set the length.
Change-Id: I722e29a13c415f2a5ff62830dce60205f273b445
Add a simple function that acts as an encryption callback to just update
the ext_seq (index) of the egress SSRC context. The kernel module
already does this, but the daemon only did it when SRTP was involved.
This now tracks egress packet indexes in all cases.
Change-Id: I9460744de55ead4b05aceb322fd8482442ff2b41
Avoid repeated calls to the memory allocated for port pool list
management by picking out the list elements without freeing them,
storing them in the stream_fd object, and then returning them to the
list when the port is released.
Change-Id: I67cd5039e62e4d2965e85d7ba7f0454f08f40494