summaryrefslogtreecommitdiffstats
path: root/Parser/tokenizer.c
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2016-09-19 06:43:18 (GMT)
committerBenjamin Peterson <benjamin@python.org>2016-09-19 06:43:18 (GMT)
commit57bda335e1ec1e5dfa7972ad118f0a1e5f539ec6 (patch)
treeaf822fd1e3dc0ed133291a1d84bd863dfe662eed /Parser/tokenizer.c
parent7eb1becc2502723ebcdcc56972e41c03ef80d6af (diff)
parent26d998cfdd1f843a154e5398d09c0270fa17aa30 (diff)
downloadcpython-57bda335e1ec1e5dfa7972ad118f0a1e5f539ec6.zip
cpython-57bda335e1ec1e5dfa7972ad118f0a1e5f539ec6.tar.gz
cpython-57bda335e1ec1e5dfa7972ad118f0a1e5f539ec6.tar.bz2
merge 3.4
Diffstat (limited to 'Parser/tokenizer.c')
-rw-r--r--Parser/tokenizer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Parser/tokenizer.c b/Parser/tokenizer.c
index eda1542..612cb23 100644
--- a/Parser/tokenizer.c
+++ b/Parser/tokenizer.c
@@ -1025,7 +1025,7 @@ tok_nextc(struct tok_state *tok)
else {
tok->done = E_OK;
tok->inp = strchr(tok->buf, '\0');
- done = tok->inp[-1] == '\n';
+ done = tok->inp == tok->buf || tok->inp[-1] == '\n';
}
}
else {