diff options
author | pooryorick <com.digitalsmarties@pooryorick.com> | 2023-04-14 07:21:48 (GMT) |
---|---|---|
committer | pooryorick <com.digitalsmarties@pooryorick.com> | 2023-04-14 07:21:48 (GMT) |
commit | d3bb4906d1397f0b5adbeb1da10ce5f6c60a8c1e (patch) | |
tree | d23852e3e0698f2db488723ac5c4fcf3056a0e5a /generic | |
parent | f7c3a988274b5e8026bf4836028bfd6831e6a615 (diff) | |
download | tcl-d3bb4906d1397f0b5adbeb1da10ce5f6c60a8c1e.zip tcl-d3bb4906d1397f0b5adbeb1da10ce5f6c60a8c1e.tar.gz tcl-d3bb4906d1397f0b5adbeb1da10ce5f6c60a8c1e.tar.bz2 |
Fix for [0cd1ae596e709259], under strict encoding, [gets] returns an error even
though a complete line is available.
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tclIO.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/generic/tclIO.c b/generic/tclIO.c index a1c13ac..aa82f89 100644 --- a/generic/tclIO.c +++ b/generic/tclIO.c @@ -4997,8 +4997,7 @@ Tcl_GetsObj( } UpdateInterest(chanPtr); TclChannelRelease((Tcl_Channel)chanPtr); - if (GotFlag(statePtr, CHANNEL_ENCODING_ERROR) && - (copiedTotal == 0 || !GotFlag(statePtr, CHANNEL_NONBLOCKING))) { + if (GotFlag(statePtr, CHANNEL_ENCODING_ERROR) && gs.bytesWrote == 0) { Tcl_SetErrno(EILSEQ); copiedTotal = -1; } |