From 1f012cc0b678fc929b5aa268fdd7f76ef18e9363 Mon Sep 17 00:00:00 2001 From: Martin Matuska Date: Mon, 2 Jan 2017 16:51:00 +0100 Subject: [PATCH] Fix build on Solaris-based systems --- libarchive/archive_write_add_filter_xz.c | 2 +- libarchive/archive_write_set_format_xar.c | 2 +- libarchive/xxhash.c | 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/libarchive/archive_write_add_filter_xz.c b/libarchive/archive_write_add_filter_xz.c index 46a6c38aa..b0f25a6ef 100644 --- a/libarchive/archive_write_add_filter_xz.c +++ b/libarchive/archive_write_add_filter_xz.c @@ -233,7 +233,7 @@ archive_compressor_xz_init_stream(struct archive_write_filter *f, if (f->code == ARCHIVE_FILTER_XZ) { #ifdef HAVE_LZMA_STREAM_ENCODER_MT if (data->threads != 1) { - bzero(&mt_options, sizeof(mt_options)); + memset(&mt_options, 0, sizeof(mt_options)); mt_options.threads = data->threads; mt_options.timeout = 300; mt_options.filters = data->lzmafilters; diff --git a/libarchive/archive_write_set_format_xar.c b/libarchive/archive_write_set_format_xar.c index ef9ad96ad..c9f5ac239 100644 --- a/libarchive/archive_write_set_format_xar.c +++ b/libarchive/archive_write_set_format_xar.c @@ -2913,7 +2913,7 @@ compression_init_encoder_xz(struct archive *a, *strm = lzma_init_data; #ifdef HAVE_LZMA_STREAM_ENCODER_MT if (threads > 1) { - bzero(&mt_options, sizeof(mt_options)); + memset(&mt_options, 0, sizeof(mt_options)); mt_options.threads = threads; mt_options.timeout = 300; mt_options.filters = lzmafilters; diff --git a/libarchive/xxhash.c b/libarchive/xxhash.c index d7f8e96de..e266bba48 100644 --- a/libarchive/xxhash.c +++ b/libarchive/xxhash.c @@ -29,10 +29,11 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. You can contact the author at : - xxHash source repository : http://code.google.com/p/xxhash/ */ +#include "archive_platform.h" + #include #include -#include "archive_platform.h" #include "archive_xxhash.h" #ifdef HAVE_LIBLZ4 -- 2.47.2