Utils/Termlib: New karmic fix
g0dil [Wed, 27 Jan 2010 14:57:39 +0000 (14:57 +0000)]
git-svn-id: https://svn.berlios.de/svnroot/repos/senf/trunk@1552 270642c3-0616-0410-b53a-bc976706d245

senf/Utils/Termlib/Telnet.cc

index df86304..0ce7e45 100644 (file)
@@ -173,7 +173,7 @@ prefix_ void senf::term::BaseTelnetProtocol::handleNormalChar(char c)
 
 prefix_ void senf::term::BaseTelnetProtocol::handleCommand(char c)
 {
-    switch (c) {
+    switch (static_cast<unsigned char>(c)) {
     case CMD_SE:
         // Ignore spurious SE commands .. they should only occur while in subnegotiation mode
         charState_ = NORMAL;
@@ -257,7 +257,7 @@ prefix_ void senf::term::BaseTelnetProtocol::handleSBData(char c)
 
 prefix_ void senf::term::BaseTelnetProtocol::handleSBIAC(char c)
 {
-    switch (c) {
+    switch (static_cast<unsigned char>(c)) {
     case CMD_IAC:
         data_.push_back(c);
         charState_ = SB_DATA;