Set the current file of the zipfile to the first file. return UNZ_OK if there is no problem */
| 1192 | return UNZ_OK if there is no problem |
| 1193 | */ |
| 1194 | extern int ZEXPORT unzGoToFirstFile (unzFile file) |
| 1195 | { |
| 1196 | int err=UNZ_OK; |
| 1197 | unz64_s* s; |
| 1198 | if (file==NULL) |
| 1199 | return UNZ_PARAMERROR; |
| 1200 | s=(unz64_s*)file; |
| 1201 | s->pos_in_central_dir=s->offset_central_dir; |
| 1202 | s->num_file=0; |
| 1203 | err=unz64local_GetCurrentFileInfoInternal(file,&s->cur_file_info, |
| 1204 | &s->cur_file_info_internal, |
| 1205 | NULL,0,NULL,0,NULL,0); |
| 1206 | s->current_file_ok = (err == UNZ_OK); |
| 1207 | if (s->cur_file_info.flag & UNZ_ENCODING_UTF8) |
| 1208 | unzSetFlags(file, UNZ_ENCODING_UTF8); |
| 1209 | return err; |
| 1210 | } |
| 1211 | |
| 1212 | /* |
| 1213 | Set the current file of the zipfile to the next file. |
no test coverage detected