[gtk] gl renderer: Don't ref transform twice



commit d228f4bb7638b68a79674f273927725808a9a89c
Author: Timm Bäder <mail baedert org>
Date:   Mon Jun 3 16:55:59 2019 +0200

    gl renderer: Don't ref transform twice
    
    That's gonna leak it otherwise.

 gsk/gl/gskglrenderops.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/gsk/gl/gskglrenderops.c b/gsk/gl/gskglrenderops.c
index 764c2eb645..ae50b22fe3 100644
--- a/gsk/gl/gskglrenderops.c
+++ b/gsk/gl/gskglrenderops.c
@@ -367,7 +367,7 @@ ops_set_modelview_internal (RenderOpBuilder *builder,
     }
 
   if (builder->current_program != NULL)
-    builder->current_program_state->modelview = gsk_transform_ref (transform);
+    builder->current_program_state->modelview = transform;
 }
 
 /* This sets the modelview to the given one without looking at the
@@ -386,7 +386,7 @@ ops_set_modelview (RenderOpBuilder *builder,
   g_array_set_size (builder->mv_stack, builder->mv_stack->len + 1);
   entry = &g_array_index (builder->mv_stack, MatrixStackEntry, builder->mv_stack->len - 1);
 
-  entry->transform = transform;
+  entry->transform = gsk_transform_ref (transform);
 
   entry->metadata.dx_before = builder->dx;
   entry->metadata.dy_before = builder->dy;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]