Skip to content
Snippets Groups Projects
Commit 2abe4f06 authored by ulif's avatar ulif
Browse files

Fix sys.stdin.seek() problem properly.

The last hotfix to make sys.stdin seek()-able was far from being
proper. It checked only for sys.stdin (which is only one possible
stream delivering unseekable file positions) and didn't consider that
sys.stdin could be replaced (by somthing with proper seek
functionality).

We now test properly for working seek() functionality. If the stream
does not support it, we copy streamdata to a new temporary file. If
the file is not too large, we keep the file data in memory (up to 20
MB), so in most cases runtime trade-off should be moderate.
parent 16b114b2
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment