diff options
author | Younes Manton <[email protected]> | 2008-12-11 23:04:51 -0500 |
---|---|---|
committer | Younes Manton <[email protected]> | 2009-01-10 13:52:06 -0500 |
commit | c10db52fcdaf1e21699fa681b701f224b1410990 (patch) | |
tree | a38d77ea5c1d49639cfb5b9aefb241e286c370b0 /src/libXvMC | |
parent | 87e39466dc49e033c4075f99343856637611b438 (diff) |
g3dvl: Fix some memory leaks.
Diffstat (limited to 'src/libXvMC')
-rw-r--r-- | src/libXvMC/context.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/libXvMC/context.c b/src/libXvMC/context.c index 698410d4c2e..273f6580292 100644 --- a/src/libXvMC/context.c +++ b/src/libXvMC/context.c @@ -182,6 +182,8 @@ Status XvMCCreateContext(Display *display, XvPortID port, int surface_type_id, i Status XvMCDestroyContext(Display *display, XvMCContext *context) { struct vlContext *vl_ctx; + struct vlScreen *vl_screen; + struct vlDisplay *vl_dpy; struct pipe_context *pipe; assert(display); @@ -194,7 +196,11 @@ Status XvMCDestroyContext(Display *display, XvMCContext *context) assert(display == vlGetNativeDisplay(vlGetDisplay(vlContextGetScreen(vl_ctx)))); pipe = vlGetPipeContext(vl_ctx); + vl_screen = vlContextGetScreen(vl_ctx); + vl_dpy = vlGetDisplay(vl_screen); vlDestroyContext(vl_ctx); + vlDestroyScreen(vl_screen); + vlDestroyDisplay(vl_dpy); destroy_pipe_context(pipe); return Success; |