| 190 | } |
| 191 | |
| 192 | bool QuaZipPrivate::goToFirstUnmappedFile() |
| 193 | { |
| 194 | zipError = UNZ_OK; |
| 195 | if (mode != QuaZip::mdUnzip) { |
| 196 | qWarning("QuaZipPrivate::goToNextUnmappedFile(): ZIP is not open in mdUnzip mode"); |
| 197 | return false; |
| 198 | } |
| 199 | // If not mapped anything, go to beginning |
| 200 | if (lastMappedDirectoryEntry.pos_in_zip_directory == 0) { |
| 201 | unzGoToFirstFile(unzFile_f); |
| 202 | } else { |
| 203 | // Goto the last one mapped, plus one |
| 204 | unzGoToFilePos64(unzFile_f, &lastMappedDirectoryEntry); |
| 205 | unzGoToNextFile(unzFile_f); |
| 206 | } |
| 207 | hasCurrentFile_f=zipError==UNZ_OK; |
| 208 | if(zipError==UNZ_END_OF_LIST_OF_FILE) |
| 209 | zipError=UNZ_OK; |
| 210 | return hasCurrentFile_f; |
| 211 | } |
| 212 | |
| 213 | QuaZip::QuaZip(): |
| 214 | p(new QuaZipPrivate(this)) |
no test coverage detected