summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAaron Watry <[email protected]>2013-11-15 16:07:31 -0600
committerAaron Watry <[email protected]>2013-12-23 07:24:50 -0600
commit20446d0e535c0735489c8944e8d767e0fc74fc6e (patch)
treef9123049b473cd4df4d2954b00f6ac5c84dc4a42 /src
parent767b0f82c37f0370c05335120e50f0a534549109 (diff)
st/vdpau: Destroy context when initialization fails
Prevents a potential memory leak found when tracking down something else. Reviewed-by: Christian König <[email protected]> Reviewed-by: Tom Stellard <[email protected]> CC: "10.0" <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/gallium/state_trackers/vdpau/device.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/gallium/state_trackers/vdpau/device.c b/src/gallium/state_trackers/vdpau/device.c
index 309fee4afae..fb9c68c26e0 100644
--- a/src/gallium/state_trackers/vdpau/device.c
+++ b/src/gallium/state_trackers/vdpau/device.c
@@ -86,6 +86,7 @@ vdp_imp_device_create_x11(Display *display, int screen, VdpDevice *device,
return VDP_STATUS_OK;
no_handle:
+ dev->context->destroy(dev->context);
/* Destroy vscreen */
no_context:
vl_screen_destroy(dev->vscreen);