diff options
author | Brian Paul <[email protected]> | 2011-07-14 08:09:21 -0600 |
---|---|---|
committer | Brian Paul <[email protected]> | 2011-07-14 08:14:13 -0600 |
commit | db0f2b363750d57652140c68c9436f1d2d540a87 (patch) | |
tree | b8d400db6f85fba95450a6a3f84f9c3f8b5e1b3d /src/mesa/main/texobj.c | |
parent | 74142f1bf2a50fb929b593ebf7fda88da9da17f9 (diff) |
mesa: use inline function wrapper for _mesa_reference_texobj()
Diffstat (limited to 'src/mesa/main/texobj.c')
-rw-r--r-- | src/mesa/main/texobj.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/mesa/main/texobj.c b/src/mesa/main/texobj.c index 0e84b874411..3021716a0b6 100644 --- a/src/mesa/main/texobj.c +++ b/src/mesa/main/texobj.c @@ -325,16 +325,14 @@ valid_texture_object(const struct gl_texture_object *tex) * Reference (or unreference) a texture object. * If '*ptr', decrement *ptr's refcount (and delete if it becomes zero). * If 'tex' is non-null, increment its refcount. + * This is normally only called from the _mesa_reference_texobj() macro + * when there's a real pointer change. */ void -_mesa_reference_texobj(struct gl_texture_object **ptr, - struct gl_texture_object *tex) +_mesa_reference_texobj_(struct gl_texture_object **ptr, + struct gl_texture_object *tex) { assert(ptr); - if (*ptr == tex) { - /* no change */ - return; - } if (*ptr) { /* Unreference the old texture */ |