aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/swrast/s_renderbuffer.c
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2014-01-20 17:47:31 +0100
committermarha <marha@users.sourceforge.net>2014-01-20 17:47:31 +0100
commit78d84bd03c744b0ed420c450dd2807904ccaef21 (patch)
tree5047a42b383693eed77091fb86950c6248681ad9 /mesalib/src/mesa/swrast/s_renderbuffer.c
parent1917325d5254a9ca33dae8ee5817dfdb7be5a24a (diff)
parent775780ea274e6602c2d64de33a98ee35979cc330 (diff)
downloadvcxsrv-78d84bd03c744b0ed420c450dd2807904ccaef21.tar.gz
vcxsrv-78d84bd03c744b0ed420c450dd2807904ccaef21.tar.bz2
vcxsrv-78d84bd03c744b0ed420c450dd2807904ccaef21.zip
Merge remote-tracking branch 'origin/released'
* origin/released: ligXext mesa git update 20 Jan 2014 fontconfig mesa git update 19 Jan 2013 Conflicts: mesalib/src/loader/Android.mk mesalib/src/loader/Makefile.am mesalib/src/loader/SConscript mesalib/src/loader/loader.c tools/mhmake/config.guess
Diffstat (limited to 'mesalib/src/mesa/swrast/s_renderbuffer.c')
-rw-r--r--mesalib/src/mesa/swrast/s_renderbuffer.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/mesalib/src/mesa/swrast/s_renderbuffer.c b/mesalib/src/mesa/swrast/s_renderbuffer.c
index e3f33de7d..a19d02ac0 100644
--- a/mesalib/src/mesa/swrast/s_renderbuffer.c
+++ b/mesalib/src/mesa/swrast/s_renderbuffer.c
@@ -659,8 +659,10 @@ _swrast_map_renderbuffers(struct gl_context *ctx)
}
for (buf = 0; buf < fb->_NumColorDrawBuffers; buf++) {
- map_attachment(ctx, fb, fb->_ColorDrawBufferIndexes[buf]);
- find_renderbuffer_colortype(fb->_ColorDrawBuffers[buf]);
+ if (fb->_ColorDrawBufferIndexes[buf] >= 0) {
+ map_attachment(ctx, fb, fb->_ColorDrawBufferIndexes[buf]);
+ find_renderbuffer_colortype(fb->_ColorDrawBuffers[buf]);
+ }
}
}
@@ -688,6 +690,8 @@ _swrast_unmap_renderbuffers(struct gl_context *ctx)
}
for (buf = 0; buf < fb->_NumColorDrawBuffers; buf++) {
- unmap_attachment(ctx, fb, fb->_ColorDrawBufferIndexes[buf]);
+ if (fb->_ColorDrawBufferIndexes[buf] >= 0) {
+ unmap_attachment(ctx, fb, fb->_ColorDrawBufferIndexes[buf]);
+ }
}
}