OSDN Git Service
(root)
/
android-x86
/
hardware-intel-common-libva.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
de8e9ed
)
Fix memory leak issue in open_display func
author
Lim Siew Hoon
<siew.hoon.lim@intel.com>
Fri, 1 Jul 2016 05:29:08 +0000
(13:29 +0800)
committer
Xiang, Haihao
<haihao.xiang@intel.com>
Fri, 22 Jul 2016 08:13:20 +0000
(16:13 +0800)
If the !d->display is true, will exit without free memory
block allocate for 'd'.
Signed-off-by: Lim Siew Hoon <siew.hoon.lim@intel.com>
test/putsurface/putsurface_wayland.c
patch
|
blob
|
history
diff --git
a/test/putsurface/putsurface_wayland.c
b/test/putsurface/putsurface_wayland.c
index
b93334d
..
c3b504f
100644
(file)
--- a/
test/putsurface/putsurface_wayland.c
+++ b/
test/putsurface/putsurface_wayland.c
@@
-207,8
+207,10
@@
open_display(void)
return NULL;
d->display = wl_display_connect(NULL);
- if (!d->display)
+ if (!d->display){
+ free(d);
return NULL;
+ }
wl_display_set_user_data(d->display, d);
d->registry = wl_display_get_registry(d->display);