- /* Save the probe setup for later. */
- g_hash_table_insert(pd_probe_maps, g_strdup(di->inst_id), probes);
- probes = NULL;
+ if (pdtok == pdtokens) {
+ /* Save the probe setup for later, but only on the first
+ * decoder -- stacked decoders don't get probes. */
+ pd_probe_maps = g_hash_table_new_full(g_str_hash,
+ g_str_equal, g_free, (GDestroyNotify)g_hash_table_destroy);
+ g_hash_table_insert(pd_probe_maps, g_strdup(di->inst_id), probes);
+ probes = NULL;
+ }