avoid following NULL pointers

This commit is contained in:
Wim Taymans 2020-05-20 13:41:48 +02:00
parent a898f21c87
commit a19bab4b16
5 changed files with 25 additions and 20 deletions

View file

@ -239,11 +239,10 @@ new_node (GstPipeWireDeviceProvider *self, struct node_data *data)
gst_structure_set (props, item->key, G_TYPE_STRING, item->value, NULL);
klass = spa_dict_lookup (info->props, PW_KEY_MEDIA_CLASS);
name = spa_dict_lookup (info->props, PW_KEY_NODE_DESCRIPTION);
}
if (klass == NULL)
klass = "unknown/unknown";
name = spa_dict_lookup (info->props, PW_KEY_NODE_DESCRIPTION);
if (name == NULL)
name = "unknown";