aboutsummaryrefslogtreecommitdiff
path: root/src/xz/options.c
diff options
context:
space:
mode:
authorLasse Collin <lasse.collin@tukaani.org>2010-09-04 23:12:20 +0300
committerLasse Collin <lasse.collin@tukaani.org>2010-09-04 23:12:20 +0300
commitc46afd6edc04ea140db6c59e8486f5707c810c13 (patch)
treeac2a473e3b98ca91e8a90137b70fd7b74ba59b18 /src/xz/options.c
parentDon't set lc=4 with --extreme. (diff)
downloadxz-c46afd6edc04ea140db6c59e8486f5707c810c13.tar.xz
xz: Use lzma_lzma_preset() to initialize the options structure.
Diffstat (limited to '')
-rw-r--r--src/xz/options.c14
1 files changed, 2 insertions, 12 deletions
diff --git a/src/xz/options.c b/src/xz/options.c
index 7186f24c..710de3b0 100644
--- a/src/xz/options.c
+++ b/src/xz/options.c
@@ -346,18 +346,8 @@ options_lzma(const char *str)
};
lzma_options_lzma *options = xmalloc(sizeof(lzma_options_lzma));
- *options = (lzma_options_lzma){
- .dict_size = LZMA_DICT_SIZE_DEFAULT,
- .preset_dict = NULL,
- .preset_dict_size = 0,
- .lc = LZMA_LC_DEFAULT,
- .lp = LZMA_LP_DEFAULT,
- .pb = LZMA_PB_DEFAULT,
- .mode = LZMA_MODE_NORMAL,
- .nice_len = 64,
- .mf = LZMA_MF_BT4,
- .depth = 0,
- };
+ if (lzma_lzma_preset(options, LZMA_PRESET_DEFAULT))
+ message_bug();
parse_options(str, opts, &set_lzma, options);