diff options
author | Victor Stinner <victor.stinner@haypocalc.com> | 2011-05-09 22:21:26 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@haypocalc.com> | 2011-05-09 22:21:26 (GMT) |
commit | 00c592553343c4cfa002071d6dc5cc1078e13f85 (patch) | |
tree | 32d0e9baa9f3abb5df320f644577f8bbad9993dd /Parser | |
parent | f2231160016bfc1c855ee602f6c73e22cc10f88b (diff) | |
parent | db932786afdd569bbf2d6b84cfd5cdcb16cb4f27 (diff) | |
download | cpython-00c592553343c4cfa002071d6dc5cc1078e13f85.zip cpython-00c592553343c4cfa002071d6dc5cc1078e13f85.tar.gz cpython-00c592553343c4cfa002071d6dc5cc1078e13f85.tar.bz2 |
(Merge 3.2) Issue #1195: Fix input() if it is interrupted by CTRL+d and then
CTRL+c, clear the end-of-file indicator after CTRL+d.
Diffstat (limited to 'Parser')
-rw-r--r-- | Parser/myreadline.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Parser/myreadline.c b/Parser/myreadline.c index 50802c3..b12d052 100644 --- a/Parser/myreadline.c +++ b/Parser/myreadline.c @@ -73,6 +73,7 @@ my_fgets(char *buf, int len, FILE *fp) } #endif /* MS_WINDOWS */ if (feof(fp)) { + clearerr(fp); return -1; /* EOF */ } #ifdef EINTR |