[gegl] operations: fix new g_object_ref() warnings
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gegl] operations: fix new g_object_ref() warnings
- Date: Wed, 4 Apr 2018 18:22:23 +0000 (UTC)
commit d7a0d88adc4bb576e0c17bc67ed3d3643643edab
Author: Michael Natterer <mitch gimp org>
Date: Wed Apr 4 20:20:29 2018 +0200
operations: fix new g_object_ref() warnings
In latest GLib, g_object_ref() returns the type that was passed in.
Cast some parameters to match the variable we assign to.
operations/core/cache.c | 2 +-
operations/core/nop.c | 3 ++-
2 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/operations/core/cache.c b/operations/core/cache.c
index c630ae2..9ac31a8 100644
--- a/operations/core/cache.c
+++ b/operations/core/cache.c
@@ -62,7 +62,7 @@ process (GeglOperation *operation,
g_clear_object (&o->cache);
if (operation->node->cache)
- o->cache = g_object_ref (operation->node->cache);
+ o->cache = g_object_ref ((GObject *) operation->node->cache);
}
return TRUE;
diff --git a/operations/core/nop.c b/operations/core/nop.c
index f393c94..d130792 100644
--- a/operations/core/nop.c
+++ b/operations/core/nop.c
@@ -62,7 +62,8 @@ gegl_nop_process (GeglOperation *operation,
return FALSE;
}
- gegl_operation_context_take_object (context, "output", g_object_ref (input));
+ gegl_operation_context_take_object (context, "output",
+ g_object_ref ((GObject *) input));
return TRUE;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]