Searched refs:za (Results 1 - 25 of 64) sorted by relevance

123

/PHP_5_6/ext/zip/examples/
H A Ddir.php6 $za = new ZipArchive(); variable
8 $za->open('test_with_comment.zip');
9 print_r($za);
10 var_dump($za);
11 echo "numFiles: " . $za->numFiles . "\n";
12 echo "status: " . $za->status . "\n";
13 echo "statusSys: " . $za->statusSys . "\n";
14 echo "filename: " . $za->filename . "\n";
15 echo "comment: " . $za->comment . "\n";
17 for ($i=0; $i<$za
[all...]
/PHP_5_6/ext/zip/lib/
H A Dzip_delete.c43 zip_delete(struct zip *za, zip_uint64_t idx)
45 if (idx >= za->nentry) {
46 _zip_error_set(&za->error, ZIP_ER_INVAL, 0);
50 if (ZIP_IS_RDONLY(za)) {
51 _zip_error_set(&za->error, ZIP_ER_RDONLY, 0);
57 if (_zip_unchange(za, idx, 1) != 0)
60 za->entry[idx].deleted = 1;
41 zip_delete(struct zip *za, zip_uint64_t idx) argument
H A Dzip_error_clear.c43 zip_error_clear(struct zip *za)
45 if (za == NULL)
48 _zip_error_clear(&za->error);
41 zip_error_clear(struct zip *za) argument
H A Dzip_error_get.c43 zip_error_get(struct zip *za, int *zep, int *sep)
45 _zip_error_get(&za->error, zep, sep);
41 zip_error_get(struct zip *za, int *zep, int *sep) argument
H A Dzip_file_replace.c43 zip_file_replace(struct zip *za, zip_uint64_t idx, struct zip_source *source, zip_flags_t flags)
45 if (idx >= za->nentry || source == NULL) {
46 _zip_error_set(&za->error, ZIP_ER_INVAL, 0);
50 if (_zip_file_replace(za, idx, NULL, source, flags) == -1)
63 _zip_file_replace(struct zip *za, zip_uint64_t idx, const char *name, struct zip_source *source, zip_flags_t flags)
67 if (ZIP_IS_RDONLY(za)) {
68 _zip_error_set(&za->error, ZIP_ER_RDONLY, 0);
72 za_nentry_prev = za->nentry;
77 i = _zip_name_locate(za, name, flags, NULL);
81 if ((i=_zip_add_entry(za)) <
41 zip_file_replace(struct zip *za, zip_uint64_t idx, struct zip_source *source, zip_flags_t flags) argument
60 _zip_file_replace(struct zip *za, zip_uint64_t idx, const char *name, struct zip_source *source, zip_flags_t flags) argument
[all...]
H A Dzip_fopen.c43 zip_fopen(struct zip *za, const char *fname, zip_flags_t flags)
47 if ((idx=zip_name_locate(za, fname, flags)) < 0)
50 return zip_fopen_index_encrypted(za, (zip_uint64_t)idx, flags, za->default_password);
41 zip_fopen(struct zip *za, const char *fname, zip_flags_t flags) argument
H A Dzip_get_num_entries.c43 zip_get_num_entries(struct zip *za, zip_flags_t flags)
47 if (za == NULL)
51 n = za->nentry;
52 while (n>0 && za->entry[n-1].orig == NULL)
56 return (zip_int64_t)za->nentry;
41 zip_get_num_entries(struct zip *za, zip_flags_t flags) argument
H A Dzip_new.c51 struct zip *za;
53 za = (struct zip *)malloc(sizeof(struct zip));
54 if (!za) {
59 za->zn = NULL;
60 za->zp = NULL;
61 za->open_flags = 0;
62 _zip_error_init(&za->error);
63 za->flags = za->ch_flags = 0;
64 za
49 struct zip *za; local
[all...]
H A Dzip_rename.c46 zip_rename(struct zip *za, zip_uint64_t idx, const char *name)
48 return zip_file_rename(za, idx, name, 0);
44 zip_rename(struct zip *za, zip_uint64_t idx, const char *name) argument
H A Dzip_replace.c44 zip_replace(struct zip *za, zip_uint64_t idx, struct zip_source *source)
46 return zip_file_replace(za, idx, source, 0);
42 zip_replace(struct zip *za, zip_uint64_t idx, struct zip_source *source) argument
H A Dzip_set_default_password.c46 zip_set_default_password(struct zip *za, const char *passwd)
48 if (za == NULL)
51 if (za->default_password)
52 free(za->default_password);
55 if ((za->default_password=strdup(passwd)) == NULL) {
56 _zip_error_set(&za->error, ZIP_ER_MEMORY, 0);
61 za->default_password = NULL;
44 zip_set_default_password(struct zip *za, const char *passwd) argument
H A Dzip_source_file.c46 zip_source_file(struct zip *za, const char *fname, zip_uint64_t start,
49 if (za == NULL)
53 _zip_error_set(&za->error, ZIP_ER_INVAL, 0);
57 return _zip_source_file_or_p(za, fname, NULL, start, len, 1, NULL);
44 zip_source_file(struct zip *za, const char *fname, zip_uint64_t start, zip_int64_t len) argument
H A Dzip_strerror.c43 zip_strerror(struct zip *za)
45 return _zip_error_strerror(&za->error);
41 zip_strerror(struct zip *za) argument
H A Dzip_unchange.c45 zip_unchange(struct zip *za, zip_uint64_t idx)
47 return _zip_unchange(za, idx, 0);
54 _zip_unchange(struct zip *za, zip_uint64_t idx, int allow_duplicates)
58 if (idx >= za->nentry) {
59 _zip_error_set(&za->error, ZIP_ER_INVAL, 0);
63 if (!allow_duplicates && za->entry[idx].changes && (za->entry[idx].changes->changed & ZIP_DIRENT_FILENAME)) {
64 i = _zip_name_locate(za, _zip_get_name(za, idx, ZIP_FL_UNCHANGED, NULL), 0, NULL);
66 _zip_error_set(&za
43 zip_unchange(struct zip *za, zip_uint64_t idx) argument
51 _zip_unchange(struct zip *za, zip_uint64_t idx, int allow_duplicates) argument
[all...]
H A Dzip_unchange_all.c45 zip_unchange_all(struct zip *za)
51 for (i=0; i<za->nentry; i++)
52 ret |= _zip_unchange(za, i, 1);
54 ret |= zip_unchange_archive(za);
43 zip_unchange_all(struct zip *za) argument
H A Dzip_unchange_archive.c45 zip_unchange_archive(struct zip *za)
47 if (za->comment_changed) {
48 _zip_string_free(za->comment_changes);
49 za->comment_changes = NULL;
50 za->comment_changed = 0;
53 za->ch_flags = za->flags;
43 zip_unchange_archive(struct zip *za) argument
H A Dzip_add.c51 zip_add(struct zip *za, const char *name, struct zip_source *source)
53 return zip_file_add(za, name, source, 0);
49 zip_add(struct zip *za, const char *name, struct zip_source *source) argument
H A Dzip_add_entry.c47 _zip_add_entry(struct zip *za)
51 if (za->nentry+1 >= za->nentry_alloc) {
53 zip_uint64_t nalloc = za->nentry_alloc + 16;
55 rentries = (struct zip_entry *)realloc(za->entry, sizeof(struct zip_entry) * (size_t)nalloc);
57 _zip_error_set(&za->error, ZIP_ER_MEMORY, 0);
60 za->entry = rentries;
61 za->nentry_alloc = nalloc;
64 idx = za->nentry++;
66 _zip_entry_init(za
45 _zip_add_entry(struct zip *za) argument
[all...]
H A Dzip_discard.c49 zip_discard(struct zip *za)
53 if (za == NULL)
56 if (za->zn)
57 free(za->zn);
59 if (za->zp)
60 fclose(za->zp);
62 free(za->default_password);
63 _zip_string_free(za->comment_orig);
64 _zip_string_free(za->comment_changes);
66 if (za
47 zip_discard(struct zip *za) argument
[all...]
H A Dzip_get_archive_flag.c43 zip_get_archive_flag(struct zip *za, zip_flags_t flag, zip_flags_t flags)
47 fl = (flags & ZIP_FL_UNCHANGED) ? za->flags : za->ch_flags;
41 zip_get_archive_flag(struct zip *za, zip_flags_t flag, zip_flags_t flags) argument
H A Dzip_get_num_files.c44 zip_get_num_files(struct zip *za)
46 if (za == NULL)
50 return (int)za->nentry;
42 zip_get_num_files(struct zip *za) argument
H A Dzip_set_archive_flag.c43 zip_set_archive_flag(struct zip *za, zip_flags_t flag, int value)
48 new_flags = za->ch_flags | flag;
50 new_flags = za->ch_flags & ~flag;
52 if (new_flags == za->ch_flags)
55 if (ZIP_IS_RDONLY(za)) {
56 _zip_error_set(&za->error, ZIP_ER_RDONLY, 0);
61 && (za->ch_flags & ZIP_AFL_RDONLY) == 0) {
62 if (_zip_changed(za, NULL)) {
63 _zip_error_set(&za->error, ZIP_ER_CHANGED, 0);
68 za
41 zip_set_archive_flag(struct zip *za, zip_flags_t flag, int value) argument
[all...]
H A Dzip_add_dir.c46 zip_add_dir(struct zip *za, const char *name)
48 return zip_dir_add(za, name, 0);
44 zip_add_dir(struct zip *za, const char *name) argument
H A Dzip_fopen_index_encrypted.c43 static struct zip_file *_zip_file_new(struct zip *za);
49 zip_fopen_index_encrypted(struct zip *za, zip_uint64_t index, zip_flags_t flags,
55 if ((src=_zip_source_zip_new(za, za, index, flags, 0, 0, password)) == NULL)
59 _zip_error_set_from_source(&za->error, src);
64 if ((zf=_zip_file_new(za)) == NULL) {
78 _zip_file_new(struct zip *za)
83 _zip_error_set(&za->error, ZIP_ER_MEMORY, 0);
87 if (za->nfile+1 >= za
47 zip_fopen_index_encrypted(struct zip *za, zip_uint64_t index, zip_flags_t flags, const char *password) argument
75 _zip_file_new(struct zip *za) argument
[all...]
H A Dzip_set_archive_comment.c45 zip_set_archive_comment(struct zip *za, const char *comment, zip_uint16_t len)
49 if (ZIP_IS_RDONLY(za)) {
50 _zip_error_set(&za->error, ZIP_ER_RDONLY, 0);
55 _zip_error_set(&za->error, ZIP_ER_INVAL, 0);
60 if ((cstr=_zip_string_new((const zip_uint8_t *)comment, len, ZIP_FL_ENC_GUESS, &za->error)) == NULL)
65 _zip_error_set(&za->error, ZIP_ER_INVAL, 0);
72 _zip_string_free(za->comment_changes);
73 za->comment_changes = NULL;
75 if (((za->comment_orig && _zip_string_equal(za
43 zip_set_archive_comment(struct zip *za, const char *comment, zip_uint16_t len) argument
[all...]

Completed in 60 milliseconds

123