Lines Matching refs:za

42 static struct zip_file *_zip_file_new(struct zip *za);
47 zip_fopen_index_encrypted(struct zip *za, zip_uint64_t fileno, int flags, in zip_fopen_index_encrypted() argument
57 if (fileno >= za->nentry) { in zip_fopen_index_encrypted()
58 _zip_error_set(&za->error, ZIP_ER_INVAL, 0); in zip_fopen_index_encrypted()
63 && ZIP_ENTRY_DATA_CHANGED(za->entry+fileno)) { in zip_fopen_index_encrypted()
64 _zip_error_set(&za->error, ZIP_ER_CHANGED, 0); in zip_fopen_index_encrypted()
68 if (fileno >= za->cdir->nentry) { in zip_fopen_index_encrypted()
69 _zip_error_set(&za->error, ZIP_ER_INVAL, 0); in zip_fopen_index_encrypted()
76 zip_stat_index(za, fileno, flags, &st); in zip_fopen_index_encrypted()
82 _zip_error_set(&za->error, ZIP_ER_NOPASSWD, 0); in zip_fopen_index_encrypted()
87 _zip_error_set(&za->error, ZIP_ER_ENCRNOTSUPP, 0); in zip_fopen_index_encrypted()
98 _zip_error_set(&za->error, ZIP_ER_COMPNOTSUPP, 0); in zip_fopen_index_encrypted()
104 if ((start=_zip_file_get_offset(za, fileno)) == 0) in zip_fopen_index_encrypted()
108 if ((src=zip_source_buffer(za, NULL, 0, 0)) == NULL) in zip_fopen_index_encrypted()
112 if ((src=_zip_source_file_or_p(za, NULL, za->zp, start, st.comp_size, in zip_fopen_index_encrypted()
116 if ((s2=enc_impl(za, src, ZIP_EM_TRAD_PKWARE, 0, in zip_fopen_index_encrypted()
125 if ((s2=comp_impl(za, src, za->cdir->entry[fileno].comp_method, in zip_fopen_index_encrypted()
135 if ((s2=zip_source_crc(za, src, 1)) == NULL) { in zip_fopen_index_encrypted()
145 _zip_error_set_from_source(&za->error, src); in zip_fopen_index_encrypted()
150 zf = _zip_file_new(za); in zip_fopen_index_encrypted()
160 _zip_file_new(struct zip *za) in _zip_file_new() argument
166 _zip_error_set(&za->error, ZIP_ER_MEMORY, 0); in _zip_file_new()
170 if (za->nfile >= za->nfile_alloc-1) { in _zip_file_new()
171 n = za->nfile_alloc + 10; in _zip_file_new()
172 file = (struct zip_file **)realloc(za->file, in _zip_file_new()
175 _zip_error_set(&za->error, ZIP_ER_MEMORY, 0); in _zip_file_new()
179 za->nfile_alloc = n; in _zip_file_new()
180 za->file = file; in _zip_file_new()
183 za->file[za->nfile++] = zf; in _zip_file_new()
185 zf->za = za; in _zip_file_new()