From 7ef393d5ff62fe50948a9df1bed43742e25de2a6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Dr=C3=B6ge?= Date: Fri, 7 Aug 2020 09:26:19 +0300 Subject: [PATCH] sctp: fix build with GST_DISABLE_GST_DEBUG Part-of: --- ext/sctp/sctpassociation.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/ext/sctp/sctpassociation.c b/ext/sctp/sctpassociation.c index ed1f92bcfb..dd98eb1766 100644 --- a/ext/sctp/sctpassociation.c +++ b/ext/sctp/sctpassociation.c @@ -174,6 +174,7 @@ gst_sctp_association_class_init (GstSctpAssociationClass * klass) g_object_class_install_properties (gobject_class, NUM_PROPERTIES, properties); } +#if defined(SCTP_DEBUG) && !defined(GST_DISABLE_GST_DEBUG) #define USRSCTP_GST_DEBUG_LEVEL GST_LEVEL_DEBUG static void gst_usrsctp_debug (const gchar * format, ...) @@ -185,13 +186,18 @@ gst_usrsctp_debug (const gchar * format, ...) __FILE__, GST_FUNCTION, __LINE__, NULL, format, varargs); va_end (varargs); } +#endif static void gst_sctp_association_init (GstSctpAssociation * self) { /* No need to lock mutex here as long as the function is only called from gst_sctp_association_get */ if (number_of_associations == 0) { +#if defined(SCTP_DEBUG) && !defined(GST_DISABLE_GST_DEBUG) usrsctp_init (0, sctp_packet_out, gst_usrsctp_debug); +#else + usrsctp_init (0, sctp_packet_out, NULL); +#endif /* Explicit Congestion Notification */ usrsctp_sysctl_set_sctp_ecn_enable (0);