From 680fc0eda85d660057999c9a7e7cfa2d5eeeae0a Mon Sep 17 00:00:00 2001 From: Brad King Date: Thu, 22 Dec 2011 16:34:21 -0500 Subject: libarchive: Fix var decl after statement in archive_string.c When HAVE_MBRTOWC is true we declare an extra local variable. Move the unused argument cast to the end of the invalid_mbs function. --- Utilities/cmlibarchive/libarchive/archive_string.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Utilities/cmlibarchive/libarchive/archive_string.c b/Utilities/cmlibarchive/libarchive/archive_string.c index 5e95dd7..5bd09bd 100644 --- a/Utilities/cmlibarchive/libarchive/archive_string.c +++ b/Utilities/cmlibarchive/libarchive/archive_string.c @@ -2287,7 +2287,6 @@ invalid_mbs(const void *_p, size_t n, struct archive_string_conv *sc) const char *p = (const char *)_p; size_t r; - (void)sc; /* UNUSED */ #if HAVE_MBRTOWC mbstate_t shift_state; @@ -2311,6 +2310,7 @@ invalid_mbs(const void *_p, size_t n, struct archive_string_conv *sc) p += r; n -= r; } + (void)sc; /* UNUSED */ return (0); /* All Okey. */ } -- cgit v0.12