Bug 219348 - [GStreamer] Common module should use a dedicated logging category
Summary: [GStreamer] Common module should use a dedicated logging category
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Platform (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Philippe Normand
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2020-11-30 05:05 PST by Philippe Normand
Modified: 2020-12-01 09:24 PST (History)
7 users (show)

See Also:


Attachments
Patch (2.24 KB, patch)
2020-12-01 08:25 PST, Philippe Normand
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Philippe Normand 2020-11-30 05:05:53 PST
We can't assume the player debug category has been initialized when logging in the common module, because that module can be used from WebAudio backend components, for instance:


STDERR: 0:00:02.188465738   132      0x248a640 DEBUG    webkitaudioprovider AudioSourceProviderGStreamer.cpp:306:handleNewDeinterleavePad: New pad <deinterleave:src_0>
STDERR: 0:00:02.188840904   132      0x248a640 DEBUG    webkitaudioprovider AudioSourceProviderGStreamer.cpp:376:deinterleavePadsConfigured: Deinterleave configured, notifying client
STDERR: 
STDERR: (WebKitWebProcess:132): GStreamer-CRITICAL **: 04:55:44.079: gst_debug_log_valist: assertion 'category != NULL' failed

Thread 1 (Thread 0x7f0517bfa180 (LWP 132)):
#0  g_logv (log_domain=0x7f051a9bd240 <g_log_domain_gstreamer> "GStreamer", log_level=G_LOG_LEVEL_CRITICAL, format=<optimized out>, args=<optimized out>) at ../glib/gmessages.c:1377
#1  0x00007f0519fdfad3 in g_log (log_domain=<optimized out>, log_level=log_level@entry=G_LOG_LEVEL_CRITICAL, format=format@entry=0x7f051a0358df "%s: assertion '%s' failed") at ../glib/gmessages.c:1415
#2  0x00007f0519fe02cd in g_return_if_fail_warning (log_domain=<optimized out>, pretty_function=pretty_function@entry=0x7f051a9cc070 <__func__.12> "gst_debug_log_valist", expression=<optimized out>) at ../glib/g
messages.c:2771
#3  0x00007f051a948bfc in gst_debug_log_valist (category=<optimized out>, level=<optimized out>, file=<optimized out>, function=<optimized out>, line=388, object=<optimized out>, format=0x7f0534f3806c "State cha
nged (old: %s, new: %s, pending: %s)", args=0x7ffde8ddf8b0) at ../gst/gstinfo.c:568
#4  0x00007f051a948cff in gst_debug_log (category=<optimized out>, level=<optimized out>, file=<optimized out>, function=<optimized out>, line=<optimized out>, object=<optimized out>, format=0x7f0534f3806c "Stat
e changed (old: %s, new: %s, pending: %s)") at ../gst/gstinfo.c:512
#5  0x00007f052f49c5ac in WebCore::simpleBusMessageCallback(_GstBus*, _GstMessage*, _GstBin*) (message=0x25b4800 [GstMessage], pipeline=0x258a0e0 [GstPipeline|WebAudioProvider_MediaStreamTrack_f4cb5d3f-a1c7-487c
-9fa5-7b5b723b84a3]) at ../../Source/WebCore/platform/graphics/gstreamer/GStreamerCommon.cpp:385
#6  0x00007f051a0ced04 in g_cclosure_marshal_VOID__BOXEDv (closure=0x250f220, return_value=<optimized out>, instance=<optimized out>, args=<optimized out>, marshal_data=<optimized out>, n_params=<optimized out>,
 param_types=0x214da10) at ../gobject/gmarshal.c:1686
#7  0x00007f051a0cbb46 in _g_closure_invoke_va (closure=closure@entry=0x250f220, return_value=return_value@entry=0x0, instance=instance@entry=0x2148720, args=args@entry=0x7ffde8ddfcd0, n_params=1, param_types=0x
214da10) at ../gobject/gclosure.c:873
#8  0x00007f051a0e4b5f in g_signal_emit_valist (instance=0x2148720, signal_id=<optimized out>, detail=236, var_args=var_args@entry=0x7ffde8ddfcd0) at ../gobject/gsignal.c:3403
#9  0x00007f051a0e4d43 in g_signal_emit (instance=instance@entry=0x2148720, signal_id=<optimized out>, detail=<optimized out>) at ../gobject/gsignal.c:3550
#10 0x00007f051a92142c in gst_bus_async_signal_func (bus=0x2148720 [GstBus|bus3], message=0x25b4800 [GstMessage], data=<optimized out>) at ../gst/gstbus.c:1295
#11 0x00007f051a92232c in gst_bus_source_dispatch (source=0x250f100, callback=0x7f051a9213d0 <gst_bus_async_signal_func>, user_data=0x0) at ../gst/gstbus.c:851
#12 0x00007f0519fd804f in g_main_dispatch (context=0x2107970) at ../glib/gmain.c:3325
#13 g_main_context_dispatch (context=0x2107970) at ../glib/gmain.c:4016
#14 0x00007f0519fd83f8 in g_main_context_iterate (context=0x2107970, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/gmain.c:4092
#15 0x00007f0519fd8713 in g_main_loop_run (loop=0x2081a00) at ../glib/gmain.c:4290
#16 0x00007f0521074fb8 in WTF::RunLoop::run() () at ../../Source/WTF/wtf/glib/RunLoopGLib.cpp:108
#17 0x00007f052f2a6028 in WebKit::AuxiliaryProcessMain<WebKit::WebProcess, WebKit::WebProcessMainGtk>(int, char**) (argc=4, argv=0x7ffde8de0118) at ../../Source/WebKit/Shared/AuxiliaryProcessMain.h:68
#18 0x00007f052f2a5d3b in WebKit::WebProcessMain(int, char**) (argc=4, argv=0x7ffde8de0118) at ../../Source/WebKit/WebProcess/gtk/WebProcessMainGtk.cpp:66
#19 0x0000000000400c56 in main(int, char**) (argc=4, argv=0x7ffde8de0118) at ../../Source/WebKit/WebProcess/EntryPoint/unix/WebProcessMain.cpp:45
Comment 1 Philippe Normand 2020-12-01 08:25:36 PST
Created attachment 415136 [details]
Patch
Comment 2 EWS 2020-12-01 09:23:28 PST
Committed r270301: <https://trac.webkit.org/changeset/270301>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 415136 [details].
Comment 3 Radar WebKit Bug Importer 2020-12-01 09:24:16 PST
<rdar://problem/71853400>