Fixes for older valac versions

This commit is contained in:
Marvin W 2021-12-25 18:25:13 +01:00
parent f591335ee3
commit 9490ffed6b
No known key found for this signature in database
GPG key ID: 072E9235DB996F2A
2 changed files with 8 additions and 3 deletions

View file

@ -43,13 +43,14 @@ public class Dino.Plugins.Ice.TransportParameters : JingleIceUdp.IceUdpTransport
if (dtls_srtp_handler != null) {
uint8[] encrypted_data = dtls_srtp_handler.process_outgoing_data(component_id, datagram.get_data());
if (encrypted_data == null) return;
// TODO: Nonblocking might require certain libnice versions?
GLib.OutputVector[] vectors = {{ encrypted_data, encrypted_data.length }};
GLib.OutputVector vector = { encrypted_data, encrypted_data.length };
GLib.OutputVector[] vectors = { vector };
Nice.OutputMessage message = { vectors };
Nice.OutputMessage[] messages = { message };
agent.send_messages_nonblocking(stream_id, component_id, messages);
} else {
GLib.OutputVector[] vectors = {{ datagram.get_data(), datagram.get_size() }};
GLib.OutputVector vector = { datagram.get_data(), datagram.get_size() };
GLib.OutputVector[] vectors = { vector };
Nice.OutputMessage message = { vectors };
Nice.OutputMessage[] messages = { message };
agent.send_messages_nonblocking(stream_id, component_id, messages);

View file

@ -20,6 +20,10 @@ if(Vala_VERSION VERSION_GREATER "0.50")
set(RTP_DEFINITIONS VALA_0_50)
endif()
if(Vala_VERSION VERSION_GREATER "0.52")
set(RTP_DEFINITIONS VALA_0_52)
endif()
if(WebRTCAudioProcessing_VERSION GREATER "0.4")
message(STATUS "Ignoring WebRTCAudioProcessing, only versions < 0.4 supported so far")
unset(WebRTCAudioProcessing_FOUND)