mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-24 01:00:37 +00:00
binaryregistry: don't crash in cleaning up on error.
Don't dereference NULL pointers.
This commit is contained in:
parent
61203b825f
commit
1949360f9b
1 changed files with 5 additions and 3 deletions
|
@ -794,9 +794,11 @@ fail_free_list:
|
|||
for (walk = to_write; walk; walk = g_list_next (walk)) {
|
||||
GstBinaryChunk *cur = walk->data;
|
||||
|
||||
if (!(cur->flags & GST_BINARY_REGISTRY_FLAG_CONST))
|
||||
g_free (cur->data);
|
||||
g_free (cur);
|
||||
if (cur) {
|
||||
if (!(cur->flags & GST_BINARY_REGISTRY_FLAG_CONST))
|
||||
g_free (cur->data);
|
||||
g_free (cur);
|
||||
}
|
||||
}
|
||||
g_list_free (to_write);
|
||||
|
||||
|
|
Loading…
Reference in a new issue