3 ms·
> It effectively reduces the I/O, while unlike TAR, allowing direct random to the files without "extracting" them or seeking through the entire file How do you
by thaumasiotes 9mo ago
> It effectively reduces the I/O, while unlike TAR, allowing direct random to the files without "extracting" them or seeking through the entire file
How do you access a particular file without seeking through the entire file? You can't know where anything is without first seeking through the whole file.
- charcircuit 9mo agoYou look at the end of the file which tells you where the central directory is. The directory tells you where individual files are.
- nikanj 9mo agoAt the end of the ZIP file, there's a central directory of all files contained in that archive. Read the last block, seek to the block containing the file you want to access, done
- thaumasiotes 9mo ago> At the end of the ZIP file, there's a central directory of all files contained in that archive. Where does that begin? > Read the last block You mean the last 4KB chunk defined by the file system, or what? The comment can be up to 64KB long.
- Dylan16807 9mo ago> You mean the last 4KB chunk defined by the file system, or what? The comment can be up to 64KB long. Okay, the last 65KB. Are you nitpicking now that you learned about the directory, or did you know about it before your first comment and pretended not to for some reason?