changeset 1213:f3ac12854587
_zip_read2 can't return values > ZIP_UINT16_MAX.
| author | Dieter Baron <dillo@nih.at> |
|---|---|
| date | Mon, 13 Aug 2012 08:43:36 +0200 |
| parents | 602bf6955b09 |
| children | 4f7bf4233c5a |
| files | TODO lib/zip_open.c |
| diffstat | 2 files changed, 1 insertions(+), 7 deletions(-) [+] |
line diff
1.1 --- a/TODO Sat Aug 11 02:44:30 2012 +0200 1.2 +++ b/TODO Mon Aug 13 08:43:36 2012 +0200 1.3 @@ -48,6 +48,7 @@ 1.4 1.5 Bugs 1.6 ==== 1.7 +! check for off_t overflow 1.8 ! fix OpenSUSE i686 regression failures 1.9 ! readd zip_get_num_files man page 1.10 ! rename remaining zip_XXX_{file,archive}_* to zip_{file,archive}_XXX_*? 1.11 @@ -69,7 +70,6 @@ 1.12 ======= 1.13 * get rid of zip_get_{compression,encryption}_implementation 1.14 * use zip_*int*_t internally 1.15 -* completely get rid of off_t 1.16 * clean up lint(1) warnings? 1.17 1.18
2.1 --- a/lib/zip_open.c Sat Aug 11 02:44:30 2012 +0200 2.2 +++ b/lib/zip_open.c Mon Aug 13 08:43:36 2012 +0200 2.3 @@ -235,12 +235,6 @@ 2.4 } 2.5 2.6 if (comment_len) { 2.7 - if (comment_len > ZIP_UINT16_MAX) { 2.8 - _zip_error_set(error, ZIP_ER_INCONS, 0); /* XXX: correct error value for archive comment too long? */ 2.9 - _zip_cdir_free(cd); 2.10 - return NULL; 2.11 - } 2.12 - 2.13 if ((cd->comment=_zip_string_new(eocd+EOCDLEN, (zip_uint16_t)comment_len, ZIP_FL_ENC_GUESS, error)) == NULL) { 2.14 _zip_cdir_free(cd); 2.15 return NULL;
