From: "Richard W.M. Jones" <rjones(a)redhat.com>
(cherry picked from commit f68d5ee16c88df4a3fe2233ba948fb4780fa2a09)
---
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 13018f0..86bb547 100644
--- a/src/cleanup.c
+++ b/src/cleanup.c
@@ -44,9 +44,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
@@ -59,9 +59,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 3e2c433..d8da33e 100644
--- a/src/guestfs-internal-frontend.h
+++ b/src/guestfs-internal-frontend.h
@@ -104,9 +104,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