projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f6f5cba
)
st/dri: Fix a memory leak in dri1_init_screen.
author
Chia-I Wu
<olv@lunarg.com>
Tue, 30 Mar 2010 07:41:31 +0000
(15:41 +0800)
committer
Chia-I Wu
<olv@lunarg.com>
Tue, 30 Mar 2010 07:41:50 +0000
(15:41 +0800)
Free the returned configs upon errors.
src/gallium/state_trackers/dri/drm/dri1.c
patch
|
blob
|
history
diff --git
a/src/gallium/state_trackers/dri/drm/dri1.c
b/src/gallium/state_trackers/dri/drm/dri1.c
index 9b5842ba2bf3d2e28d9fcc42e4c2eb39355a2c9f..cca7cd8f0c3805bbbaa973a78f2a95acf91cad1c 100644
(file)
--- a/
src/gallium/state_trackers/dri/drm/dri1.c
+++ b/
src/gallium/state_trackers/dri/drm/dri1.c
@@
-514,6
+514,8
@@
dri1_init_screen(__DRIscreen * sPriv)
return configs;
fail:
+ if (configs)
+ FREE(configs);
dri_destroy_screen_helper(screen);
FREE(screen);
return NULL;