info: Fix deadlock in gst_ring_buffer_logger_log
authorDoug Nazar <nazard@nazar.ca>
Wed, 31 Jul 2019 01:40:47 +0000 (21:40 -0400)
committerTim-Philipp Müller <tim@centricular.com>
Thu, 8 Aug 2019 23:27:04 +0000 (00:27 +0100)
commit815acd88ee9947a1f5ceb3255dd17eed1179dabc
treeb3c36359a811bbb43885ed3f38c1eb533a90cb18
parent819b316e039c5974e1b06bf25e4f68dc74ab00a0
info: Fix deadlock in gst_ring_buffer_logger_log

gst_ring_buffer_logger_log calls several functions while formatting
the message which may in turn log a message while we already hold
the mutex. Do all formatting first before acquiring the mutex to
avoid this and reduce the time we hold the mutex.
gst/gstinfo.c