Also, I'm not sure what (specifically) read-line looks for to stop reading, but if it can occur randomly you could receive errors if this first random new-line occurs before the length of the file's first line. Or at all when using the same pad for many files as you describe. This may be handled by your %octets-to-string handler though.