From b4f0ab9002559b774407fb692bcc7e83a6c82ab7 Mon Sep 17 00:00:00 2001 From: Eric Biggers Date: Thu, 12 Jun 2014 23:04:05 -0500 Subject: [PATCH] Remove WIMLIB_COMPRESSION_TYPE_INVALID from library This is actually only used in wimlib-imagex --- include/wimlib.h | 3 --- programs/imagex.c | 2 ++ src/wim.c | 2 -- src/write.c | 5 ++--- 4 files changed, 4 insertions(+), 8 deletions(-) diff --git a/include/wimlib.h b/include/wimlib.h index 5e49f92e..3cc83350 100644 --- a/include/wimlib.h +++ b/include/wimlib.h @@ -424,9 +424,6 @@ typedef char wimlib_tchar; * Specifies the compression type of a WIM file. */ enum wimlib_compression_type { - /** An invalid compression type. */ - WIMLIB_COMPRESSION_TYPE_INVALID = -1, - /** The WIM does not include any compressed resources. */ WIMLIB_COMPRESSION_TYPE_NONE = 0, diff --git a/programs/imagex.c b/programs/imagex.c index 81f2f9f6..50803014 100644 --- a/programs/imagex.c +++ b/programs/imagex.c @@ -46,6 +46,8 @@ # include #endif +#define WIMLIB_COMPRESSION_TYPE_INVALID (-1) + #ifdef __WIN32__ # include "imagex-win32.h" # define print_security_descriptor win32_print_security_descriptor diff --git a/src/wim.c b/src/wim.c index 2dd07872..cf7965e7 100644 --- a/src/wim.c +++ b/src/wim.c @@ -549,8 +549,6 @@ static int set_out_ctype(int ctype, u8 *out_ctype_p) { switch (ctype) { - case WIMLIB_COMPRESSION_TYPE_INVALID: - break; case WIMLIB_COMPRESSION_TYPE_NONE: case WIMLIB_COMPRESSION_TYPE_LZX: case WIMLIB_COMPRESSION_TYPE_XPRESS: diff --git a/src/write.c b/src/write.c index aa3585a7..5bca038a 100644 --- a/src/write.c +++ b/src/write.c @@ -1261,9 +1261,8 @@ remove_zero_length_streams(struct list_head *stream_list) * * @out_ctype * Compression format to use to write the output streams, specified as one - * of the WIMLIB_COMPRESSION_TYPE_* constants, excepting - * WIMLIB_COMPRESSION_TYPE_INVALID but including - * WIMLIB_COMPRESSION_TYPE_NONE. + * of the WIMLIB_COMPRESSION_TYPE_* constants. + * WIMLIB_COMPRESSION_TYPE_NONE is allowed. * * @out_chunk_size * Chunk size to use to write the streams. It must be a valid chunk size -- 2.43.0