]> sigrok.org Git - libsigrokdecode.git/commitdiff
instance.c: Add a debug message for thread creation.
authorUwe Hermann <redacted>
Mon, 27 Feb 2017 07:42:44 +0000 (08:42 +0100)
committerUwe Hermann <redacted>
Mon, 27 Feb 2017 11:43:44 +0000 (12:43 +0100)
instance.c

index e80afd751469b7fb6d81acac51cdff3591131019..1753912147a5fc6d2942a1015b11cee3c1856e86 100644 (file)
@@ -1054,9 +1054,12 @@ SRD_PRIV int srd_inst_decode(struct srd_decoder_inst *di,
                Py_DecRef(py_res);
        } else {
                /* If this is the first call, start the worker thread. */
-               if (!di->thread_handle)
-                       di->thread_handle = g_thread_new("di_thread",
+               if (!di->thread_handle) {
+                       srd_dbg("No worker thread for this decoder stack "
+                               "exists yet, creating one: %s.", di->inst_id);
+                       di->thread_handle = g_thread_new(di->inst_id,
                                                         di_thread, di);
+               }
 
                /* Push the new sample chunk to the worker thread. */
                g_mutex_lock(&di->data_mutex);