diff options
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tclIO.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/generic/tclIO.c b/generic/tclIO.c index ed94bfe..b7135e9 100644 --- a/generic/tclIO.c +++ b/generic/tclIO.c @@ -2415,6 +2415,11 @@ DiscardOutputQueued( } statePtr->outQueueHead = NULL; statePtr->outQueueTail = NULL; + bufPtr = statePtr->curOutPtr; + if (bufPtr && BytesLeft(bufPtr)) { + statePtr->curOutPtr = NULL; + RecycleBuffer(statePtr, bufPtr, 0); + } } /* |