summaryrefslogtreecommitdiffstats
path: root/libmpv
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2016-03-22 10:01:59 +0100
committerwm4 <wm4@nowhere>2016-03-22 10:01:59 +0100
commitc8b6ca9070a7e0ed0826e86b3948af57ce7aeaa2 (patch)
tree8f6ed24f6484bb510d879ad2df0cf1bef542da2e /libmpv
parentd6c99c8513a02c6dc7187d799c88327c858619c4 (diff)
downloadmpv-c8b6ca9070a7e0ed0826e86b3948af57ce7aeaa2.tar.bz2
mpv-c8b6ca9070a7e0ed0826e86b3948af57ce7aeaa2.tar.xz
qthelper: fix potential NULL deref in error path
Found by clang-tidy.
Diffstat (limited to 'libmpv')
-rw-r--r--libmpv/qthelper.hpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/libmpv/qthelper.hpp b/libmpv/qthelper.hpp
index c25315f3b4..70b3baffc4 100644
--- a/libmpv/qthelper.hpp
+++ b/libmpv/qthelper.hpp
@@ -202,9 +202,9 @@ private:
if (list->values)
free_node(&list->values[n]);
}
+ delete[] list->keys;
+ delete[] list->values;
}
- delete[] list->keys;
- delete[] list->values;
delete list;
break;
}