From 13c4e8415e2f86e6dc389d6b53bd54aa1c50d8c2 Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Sat, 22 Aug 2015 17:57:48 +0000 Subject: Minor tweak to non-canoninical callback handling. It had the same problem that the canonical mode had so long ago. --- src/stable/protocoltelnet.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/stable/protocoltelnet.cpp b/src/stable/protocoltelnet.cpp index 77bc3dc..f6fbd4b 100644 --- a/src/stable/protocoltelnet.cpp +++ b/src/stable/protocoltelnet.cpp @@ -269,9 +269,11 @@ void Bu::ProtocolTelnet::onNewData( Bu::Client *pClient ) // IAC code or multibyte escape sequence or something, but then again, it // shouldn't be called then, and really, shouldn't be, it'll be called soon // enough, when we get the rest of that code. - if( !bCanonical ) + if( !bCanonical && !sDataBuf.isEmpty() ) { - gotData( sDataBuf ); + Bu::String sDat = sDataBuf; + sDataBuf.clear(); + gotData( sDat ); } } -- cgit v1.2.3