Lines Matching refs:f
46 FILE *f; /* file to copy from */ member
83 struct read_file *f; in _zip_source_file_or_p() local
91 if ((f=(struct read_file *)malloc(sizeof(struct read_file))) == NULL) { in _zip_source_file_or_p()
96 f->fname = NULL; in _zip_source_file_or_p()
98 if ((f->fname=strdup(fname)) == NULL) { in _zip_source_file_or_p()
100 free(f); in _zip_source_file_or_p()
104 f->f = file; in _zip_source_file_or_p()
105 f->off = start; in _zip_source_file_or_p()
106 f->len = (len ? len : -1); in _zip_source_file_or_p()
107 f->closep = f->fname ? 1 : closep; in _zip_source_file_or_p()
109 memcpy(&f->st, st, sizeof(f->st)); in _zip_source_file_or_p()
111 zip_stat_init(&f->st); in _zip_source_file_or_p()
113 if ((zs=zip_source_function(za, read_file, f)) == NULL) { in _zip_source_file_or_p()
114 free(f); in _zip_source_file_or_p()
137 if ((z->f=fopen(z->fname, "rb")) == NULL) { in read_file()
145 if (fseeko(z->f, (off_t)z->off, SEEK_SET) < 0) { in read_file()
165 if (fseeko(z->f, (off_t)(z->off + (zip_uint64_t)(z->len-z->remain)), SEEK_SET) < 0) { in read_file()
172 if ((i=fread(buf, 1, (size_t)n, z->f)) == 0) { in read_file()
173 if (ferror(z->f)) { in read_file()
187 fclose(z->f); in read_file()
188 z->f = NULL; in read_file()
204 if (z->f) in read_file()
205 err = fstat(fileno(z->f), &fst); in read_file()
241 if (z->closep && z->f) in read_file()
242 fclose(z->f); in read_file()