--- a/sources/network/rconsession.cpp Tue May 26 18:19:27 2015 +0300 +++ b/sources/network/rconsession.cpp Tue May 26 18:46:24 2015 +0300 @@ -42,7 +42,7 @@ { if (not m_socket.set_blocking (false)) { - print_to (stderr, "unable to set socket as non-blocking: %1\n", + fprintf (stderr, "unable to set socket as non-blocking: %s\n", m_socket.error_string().chars()); exit (EXIT_FAILURE); } @@ -72,7 +72,7 @@ Bytestream packet; packet.write_byte (CLRC_DISCONNECT); this->send (packet); - m_interface->print ("Disconnected from %1\n", m_address.to_string (IP_WITH_PORT)); + m_interface->print ("Disconnected from %s\n", m_address.to_string (IP_WITH_PORT).chars()); m_interface->update_statusbar(); } @@ -159,7 +159,7 @@ { String message = packet.read_string(); message.normalize(); - m_interface->print ("%1\n", message); + m_interface->print ("%s\n", message.chars()); } break; @@ -179,7 +179,7 @@ { String message = packet.read_string(); message.normalize(); - m_interface->print ("--- %1\n", message); + m_interface->print ("--- %s\n", message.chars()); } m_interface->print ("End of previous messages.\n"); @@ -192,8 +192,8 @@ case SVRC_TOOMANYTABCOMPLETES: { unsigned int numCompletions = packet.read_short(); - m_interface->print ("%1 completions for '%2'.\n", - int (numCompletions), m_lastTabComplete); + m_interface->print ("%d completions for '%s'.\n", + int (numCompletions), m_lastTabComplete.chars()); } break; @@ -210,13 +210,13 @@ } else if (not completes.is_empty()) { - m_interface->print ("Completions for '%1':\n", m_lastTabComplete); + m_interface->print ("Completions for '%s':\n", m_lastTabComplete.chars()); for (int i = 0; i < completes.size(); i += 8) { Range<int> spliceRange (i, min (i + 8, completes.size() - 1)); StringList splice (completes.splice (spliceRange)); - m_interface->print ("- %1\n", splice.join (", ")); + m_interface->print ("- %s\n", splice.join (", ").chars()); } } } @@ -226,7 +226,7 @@ } catch (std::exception& e) { - m_interface->print_warning ("Couldn't process packet: %1\n", e.what()); + m_interface->print_warning ("Couldn't process packet: %s\n", e.what()); } } @@ -274,7 +274,7 @@ // void RCONSession::send_hello() { - m_interface->print ("Connecting to %1...\n", m_address.to_string (IP_WITH_PORT)); + m_interface->print ("Connecting to %s...\n", m_address.to_string (IP_WITH_PORT).chars()); Bytestream packet; packet.write_byte (CLRC_BEGINCONNECTION); packet.write_byte (RCON_PROTOCOL_VERSION); @@ -375,5 +375,7 @@ m_lastTabComplete = part; } else - m_interface->print ("Server protocol is %1, cannot tab-complete\n", m_serverProtocol); + { + m_interface->print ("This server does not support tab-completion\n", m_serverProtocol); + } } \ No newline at end of file