[gnome-builder] context: use G_TYPE_CHECK_INSTANCE_TYPE()
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder] context: use G_TYPE_CHECK_INSTANCE_TYPE()
- Date: Thu, 18 Jan 2018 14:42:47 +0000 (UTC)
commit 5fbcad2e13c6a9ef37d5dfdaf08298550ceaea60
Author: Christian Hergert <chergert redhat com>
Date: Tue Jan 16 19:04:03 2018 -0800
context: use G_TYPE_CHECK_INSTANCE_TYPE()
This is a a better type instance check since we use the actual value from
the hash table.
src/libide/ide-context.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/src/libide/ide-context.c b/src/libide/ide-context.c
index 2667ccef4..64f2ea85e 100644
--- a/src/libide/ide-context.c
+++ b/src/libide/ide-context.c
@@ -512,7 +512,7 @@ ide_context_get_service_typed (IdeContext *self,
while (g_hash_table_iter_next (&iter, &key, &value))
{
- if (g_type_is_a (service_type, GPOINTER_TO_SIZE (key)))
+ if (G_TYPE_CHECK_INSTANCE_TYPE (value, service_type))
return value;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]