projects
/
platform
/
upstream
/
libxkbcommon.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3515ba1
)
test: fix a potential memory leak
author
Peter Hutterer
<peter.hutterer@who-t.net>
Tue, 5 Nov 2019 03:22:49 +0000
(13:22 +1000)
committer
Ran Benita
<ran234@gmail.com>
Thu, 7 Nov 2019 09:10:00 +0000
(11:10 +0200)
Found by coverity
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
test/common.c
patch
|
blob
|
history
diff --git
a/test/common.c
b/test/common.c
index
c371272
..
fbe72a7
100644
(file)
--- a/
test/common.c
+++ b/
test/common.c
@@
-247,8
+247,10
@@
test_get_context(enum test_context_flags test_flags)
return NULL;
path = test_get_path("");
- if (!path)
+ if (!path) {
+ xkb_context_unref(ctx);
return NULL;
+ }
xkb_context_include_path_append(ctx, path);
free(path);