diff options
author | Younes Manton <[email protected]> | 2009-01-13 22:58:43 -0500 |
---|---|---|
committer | Younes Manton <[email protected]> | 2009-01-18 21:40:10 -0500 |
commit | 11f91936f21c1ab0b38f0f84bb2cbf82f9cadece (patch) | |
tree | ec93e2fcf98e33d295e18b2a3e139f21244c7b4f /src/gallium/state_trackers | |
parent | c35dc4a741d4147a5da8bbe834a38a4c2ce627d1 (diff) |
g3dvl: Return BadAlloc if we can't create an XvMC surface.
Diffstat (limited to 'src/gallium/state_trackers')
-rw-r--r-- | src/gallium/state_trackers/g3dvl/vl_surface.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gallium/state_trackers/g3dvl/vl_surface.c b/src/gallium/state_trackers/g3dvl/vl_surface.c index 911469f966a..612438f2ac3 100644 --- a/src/gallium/state_trackers/g3dvl/vl_surface.c +++ b/src/gallium/state_trackers/g3dvl/vl_surface.c @@ -51,6 +51,12 @@ int vlCreateSurface sfc->texture = vlGetPipeScreen(screen)->texture_create(vlGetPipeScreen(screen), &template); + if (!sfc->texture) + { + FREE(sfc); + return 1; + } + *surface = sfc; return 0; |