projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8978e45
)
st/mesa: Move dereference and assignment to after NULL check.
author
Vinson Lee
<vlee@vmware.com>
Fri, 16 Apr 2010 06:15:05 +0000
(23:15 -0700)
committer
Vinson Lee
<vlee@vmware.com>
Fri, 16 Apr 2010 06:15:05 +0000
(23:15 -0700)
src/mesa/state_tracker/st_cb_texture.c
patch
|
blob
|
history
diff --git
a/src/mesa/state_tracker/st_cb_texture.c
b/src/mesa/state_tracker/st_cb_texture.c
index 196bf1325fbd49d261125de074f8c8240d6e0cbd..9479819e8334d6c67423a9c42b55820f67517b51 100644
(file)
--- a/
src/mesa/state_tracker/st_cb_texture.c
+++ b/
src/mesa/state_tracker/st_cb_texture.c
@@
-1213,10
+1213,11
@@
st_CompressedTexSubImage2D(GLcontext *ctx, GLenum target, GLint level,
int srcBlockStride;
int dstBlockStride;
int y;
- enum pipe_format pformat
= stImage->pt->format
;
+ enum pipe_format pformat;
if (stImage->pt) {
unsigned face = _mesa_tex_target_to_face(target);
+ pformat = stImage->pt->format;
st_teximage_flush_before_map(ctx->st, stImage->pt, face, level,
PIPE_TRANSFER_WRITE);