From: "Richard W.M. Jones" <rjones(a)redhat.com>
(cherry picked from commit f68d5ee16c88df4a3fe2233ba948fb4780fa2a09)
(cherry picked from commit 61f4a56c9d8c17d9467ef902b96c5886222be661)
---
src/cleanup.c | 8 ++++----
src/guestfs-internal-frontend.h | 4 ++--
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/src/cleanup.c b/src/cleanup.c
index ef2e8ed..ebd3446 100644
--- a/src/cleanup.c
+++ b/src/cleanup.c
@@ -46,9 +46,9 @@ guestfs___cleanup_free (void *ptr)
}
void
-guestfs___cleanup_free_string_list (void *ptr)
+guestfs___cleanup_free_string_list (char ***ptr)
{
- guestfs___free_string_list (* (char ***) ptr);
+ guestfs___free_string_list (*ptr);
}
void
@@ -61,9 +61,9 @@ guestfs___cleanup_hash_free (void *ptr)
}
void
-guestfs___cleanup_unlink_free (void *ptr)
+guestfs___cleanup_unlink_free (char **ptr)
{
- char *filename = * (char **) ptr;
+ char *filename = *ptr;
if (filename) {
unlink (filename);
diff --git a/src/guestfs-internal-frontend.h b/src/guestfs-internal-frontend.h
index ca1701f..eba1c0e 100644
--- a/src/guestfs-internal-frontend.h
+++ b/src/guestfs-internal-frontend.h
@@ -102,9 +102,9 @@ extern char *guestfs___drive_name (size_t index, char *ret);
* Don't call them directly.
*/
extern void guestfs___cleanup_free (void *ptr);
-extern void guestfs___cleanup_free_string_list (void *ptr);
+extern void guestfs___cleanup_free_string_list (char ***ptr);
extern void guestfs___cleanup_hash_free (void *ptr);
-extern void guestfs___cleanup_unlink_free (void *ptr);
+extern void guestfs___cleanup_unlink_free (char **ptr);
extern void guestfs___cleanup_xmlBufferFree (void *ptr);
extern void guestfs___cleanup_xmlFreeDoc (void *ptr);
extern void guestfs___cleanup_xmlFreeURI (void *ptr);
--
1.8.3.1