From bcc19e88fbd5395f07f7523e9f6bcafc3b9e9807 Mon Sep 17 00:00:00 2001 From: Zebediah Figura Date: Sat, 10 Jul 2021 19:22:18 -0500 Subject: [PATCH] winegstreamer: Avoid using WARN_ON from a GStreamer callback. Signed-off-by: Zebediah Figura Signed-off-by: Alexandre Julliard --- dlls/winegstreamer/wg_parser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/winegstreamer/wg_parser.c b/dlls/winegstreamer/wg_parser.c index 4689c83413b..a2eb5415c7b 100644 --- a/dlls/winegstreamer/wg_parser.c +++ b/dlls/winegstreamer/wg_parser.c @@ -977,7 +977,7 @@ static gboolean sink_query_cb(GstPad *pad, GstObject *parent, GstQuery *query) gst_query_parse_accept_caps(query, &caps); wg_format_from_caps(&format, caps); ret = wg_format_compare(&format, &stream->current_format); - if (!ret && WARN_ON(gstreamer)) + if (!ret && gst_debug_category_get_threshold(GST_CAT_DEFAULT) >= GST_LEVEL_WARNING) { gchar *str = gst_caps_to_string(caps); GST_WARNING("Rejecting caps \"%s\".", str);