diff --git a/src/compositor/meta-shaped-texture.c b/src/compositor/meta-shaped-texture.c index 9a5e18386..8d45d9bf0 100644 --- a/src/compositor/meta-shaped-texture.c +++ b/src/compositor/meta-shaped-texture.c @@ -227,10 +227,11 @@ set_cogl_texture (MetaShapedTexture *stex, if (priv->texture) cogl_object_unref (priv->texture); - priv->texture = cogl_object_ref (cogl_tex); + priv->texture = cogl_tex; if (cogl_tex != NULL) { + cogl_object_ref (cogl_tex); width = cogl_texture_get_width (COGL_TEXTURE (cogl_tex)); height = cogl_texture_get_height (COGL_TEXTURE (cogl_tex));