A small subset of files (e.g. etext98/sesli10.zip, etext04/stryb10.zip) have a JPEG as the first entry in their ZIP file from the ISO, which the code blithely interprets as a text file (since it's only looking for the first entry in the ZIP, see this line). It should probably only look at files with a particular extension (i.e., .txt).