summaryrefslogtreecommitdiff
path: root/girepository
diff options
context:
space:
mode:
authorChristoph Reiter <reiter.christoph@gmail.com>2018-07-29 15:24:59 +0200
committerChristoph Reiter <reiter.christoph@gmail.com>2018-07-29 18:56:58 +0200
commit54e8b9b96e4553b4a05e95612d0a91677e85f9e8 (patch)
tree94cd99b3f91321b55bf33d015441efcf7e0fc55c /girepository
parent769f7602dc5762fe1df3c44a0dd2f2b2fcc39dd8 (diff)
downloadgobject-introspection-54e8b9b96e4553b4a05e95612d0a91677e85f9e8.tar.gz
build: enable -Wcast-function-type
Where it's easy add dummy args to match the cast; where the target is a subset just prevent the warning with a cast to void*. Provide a real copy function for the boxed type code in regress_foo. This code is never executed afaics, but why not.
Diffstat (limited to 'girepository')
-rw-r--r--girepository/girepository.c2
-rw-r--r--girepository/gitypelib.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/girepository/girepository.c b/girepository/girepository.c
index 10282c72..6ffb3aa8 100644
--- a/girepository/girepository.c
+++ b/girepository/girepository.c
@@ -1362,7 +1362,7 @@ find_namespace_latest (const gchar *namespace,
*path_ret = elected->path;
*version_ret = elected->version;
g_slice_free (struct NamespaceVersionCandidadate, elected); /* just free the container */
- g_slist_foreach (candidates, (GFunc) free_candidate, NULL);
+ g_slist_foreach (candidates, (GFunc) (void *) free_candidate, NULL);
g_slist_free (candidates);
}
return result;
diff --git a/girepository/gitypelib.c b/girepository/gitypelib.c
index f2b20607..1e33c6af 100644
--- a/girepository/gitypelib.c
+++ b/girepository/gitypelib.c
@@ -2455,7 +2455,7 @@ g_typelib_free (GITypelib *typelib)
g_free (typelib->data);
if (typelib->modules)
{
- g_list_foreach (typelib->modules, (GFunc) g_module_close, NULL);
+ g_list_foreach (typelib->modules, (GFunc) (void *) g_module_close, NULL);
g_list_free (typelib->modules);
}
g_slice_free (GITypelib, typelib);