diff options
author | Eric Anholt <[email protected]> | 2010-03-12 17:12:14 -0800 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2010-03-16 13:18:54 -0700 |
commit | 7cbb7051f42c0220b35ce1e834853dac8706a69a (patch) | |
tree | 48d15ed84b2de6eeb3ce37300a70148429851b83 | |
parent | 541c9c08e575ea93768c2e2cb889d9b236caf40f (diff) |
meta: Fix up restoration of state if _mesa_map_pbo_source() fails.
-rw-r--r-- | src/mesa/drivers/common/meta.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mesa/drivers/common/meta.c b/src/mesa/drivers/common/meta.c index b29f58db729..84a2a5fcb3a 100644 --- a/src/mesa/drivers/common/meta.c +++ b/src/mesa/drivers/common/meta.c @@ -2067,8 +2067,10 @@ _mesa_meta_Bitmap(GLcontext *ctx, } bitmap1 = _mesa_map_pbo_source(ctx, &unpackSave, bitmap1); - if (!bitmap1) + if (!bitmap1) { + _mesa_meta_end(ctx); return; + } bitmap8 = (GLubyte *) calloc(1, width * height); if (bitmap8) { |