diff options
author | Mounir IDRASSI <mounir.idrassi@idrix.fr> | 2017-04-26 00:10:55 +0200 |
---|---|---|
committer | Mounir IDRASSI <mounir.idrassi@idrix.fr> | 2017-04-26 00:20:19 +0200 |
commit | d081d6143e86bd350bd62dc6811629346746ac52 (patch) | |
tree | 24559cfc688a694d1fb085b000228118eb845f32 /src/Common/libzip/zip_stat_index.c | |
parent | 9270952b3dd956ba2f6b2e444768354bee3ae5e2 (diff) | |
download | VeraCrypt-d081d6143e86bd350bd62dc6811629346746ac52.tar.gz VeraCrypt-d081d6143e86bd350bd62dc6811629346746ac52.zip |
Windows: update libzip to version 1.2.0
Diffstat (limited to 'src/Common/libzip/zip_stat_index.c')
-rw-r--r-- | src/Common/libzip/zip_stat_index.c | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/src/Common/libzip/zip_stat_index.c b/src/Common/libzip/zip_stat_index.c index 601e3f70..a2ef59bb 100644 --- a/src/Common/libzip/zip_stat_index.c +++ b/src/Common/libzip/zip_stat_index.c @@ -1,6 +1,6 @@ /* zip_stat_index.c -- get information about file by index - Copyright (C) 1999-2014 Dieter Baron and Thomas Klausner + Copyright (C) 1999-2016 Dieter Baron and Thomas Klausner This file is part of libzip, a library to manipulate ZIP archives. The authors can be contacted at <libzip@nih.at> @@ -64,17 +64,8 @@ zip_stat_index(zip_t *za, zip_uint64_t index, zip_flags_t flags, st->mtime = de->last_mod; st->comp_size = de->comp_size; st->comp_method = (zip_uint16_t)de->comp_method; - if (de->bitflags & ZIP_GPBF_ENCRYPTED) { - if (de->bitflags & ZIP_GPBF_STRONG_ENCRYPTION) { - /* TODO */ - st->encryption_method = ZIP_EM_UNKNOWN; - } - else - st->encryption_method = ZIP_EM_TRAD_PKWARE; - } - else - st->encryption_method = ZIP_EM_NONE; - st->valid = ZIP_STAT_CRC|ZIP_STAT_SIZE|ZIP_STAT_MTIME + st->encryption_method = de->encryption_method; + st->valid = (de->crc_valid ? ZIP_STAT_CRC : 0) | ZIP_STAT_SIZE|ZIP_STAT_MTIME |ZIP_STAT_COMP_SIZE|ZIP_STAT_COMP_METHOD|ZIP_STAT_ENCRYPTION_METHOD; } |