Browse Source

Fix infinite loop at end of WARC

master
JustAnotherArchivist 5 years ago
parent
commit
641bc7a207
1 changed files with 2 additions and 0 deletions
  1. +2
    -0
      warc-tiny

+ 2
- 0
warc-tiny View File

@@ -80,6 +80,8 @@ def iter_warc(f):
buf = buf + fp.read(4096)
except EOFError:
break
if not buf:
break
if not buf:
break
warcHeaderBuf, buf = buf.split(b'\r\n\r\n', 1)


Loading…
Cancel
Save