From 5f41fe03ca0abfe43e386426ce942414d8602706 Mon Sep 17 00:00:00 2001 From: Bill Hoffman Date: Tue, 3 Nov 2009 16:50:49 -0500 Subject: [PATCH] Fix warnings for unused variables --- Source/CPack/cmCPackArchiveGenerator.cxx | 6 +++--- Source/cmSystemTools.cxx | 3 +-- Utilities/cmbzip2/bzlib.c | 3 +++ 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/Source/CPack/cmCPackArchiveGenerator.cxx b/Source/CPack/cmCPackArchiveGenerator.cxx index e6a83b13fc..9d8edf80c2 100644 --- a/Source/CPack/cmCPackArchiveGenerator.cxx +++ b/Source/CPack/cmCPackArchiveGenerator.cxx @@ -115,7 +115,7 @@ struct StreamData extern "C" { -int OpenArchive(struct archive *a, void *client_data) +int OpenArchive(struct archive *, void *client_data) { struct StreamData *data = (StreamData*)client_data; if(data->GeneratedFileStream && @@ -130,7 +130,7 @@ int OpenArchive(struct archive *a, void *client_data) return (ARCHIVE_FATAL); } -__LA_SSIZE_T WriteArchive(struct archive *a, +__LA_SSIZE_T WriteArchive(struct archive *, void *client_data, const void *buff, size_t n) @@ -146,7 +146,7 @@ __LA_SSIZE_T WriteArchive(struct archive *a, } -int CloseArchive(struct archive *a, void *client_data) +int CloseArchive(struct archive *, void *client_data) { struct StreamData *data = (StreamData*)client_data; if(data->GeneratedFileStream->Close()) diff --git a/Source/cmSystemTools.cxx b/Source/cmSystemTools.cxx index d593d7e9a7..b487c5c5dc 100644 --- a/Source/cmSystemTools.cxx +++ b/Source/cmSystemTools.cxx @@ -2051,7 +2051,7 @@ bool cmSystemTools::ExtractTar(const char* outFileName, } bool cmSystemTools::ListTar(const char* outFileName, - std::vector& files, bool gzip, + std::vector& files, bool , bool verbose) { #if defined(CMAKE_BUILD_WITH_CMAKE) @@ -2059,7 +2059,6 @@ bool cmSystemTools::ListTar(const char* outFileName, #else (void)outFileName; (void)files; - (void)gzip; (void)verbose; return false; #endif diff --git a/Utilities/cmbzip2/bzlib.c b/Utilities/cmbzip2/bzlib.c index baed28849f..aeecef10f7 100644 --- a/Utilities/cmbzip2/bzlib.c +++ b/Utilities/cmbzip2/bzlib.c @@ -102,6 +102,7 @@ static void* default_bzalloc ( void* opaque, Int32 items, Int32 size ) { void* v = malloc ( items * size ); + (void)opaque; return v; } @@ -109,6 +110,7 @@ static void default_bzfree ( void* opaque, void* addr ) { if (addr != NULL) free ( addr ); + (void)opaque; } @@ -1505,6 +1507,7 @@ int BZ_API(BZ2_bzwrite) (BZFILE* b, void* buf, int len ) /*---------------------------------------------------*/ int BZ_API(BZ2_bzflush) (BZFILE *b) { + (void) b; /* do nothing now... */ return 0; }