summaryrefslogtreecommitdiffstats
path: root/src/networkinterface.cpp
diff options
context:
space:
mode:
authorSlávek Banko <[email protected]>2018-12-16 05:16:48 +0100
committerSlávek Banko <[email protected]>2018-12-16 11:28:29 +0100
commit6284823847949bb94a9974bc49befb14d9513b47 (patch)
treec0edff6a7f82c84531fdf8ed1b89fe3eab336e56 /src/networkinterface.cpp
parentedd94929b6f5cec0621460553c6d5c704cc13691 (diff)
downloadkvpnc-6284823847949bb94a9974bc49befb14d9513b47.tar.gz
kvpnc-6284823847949bb94a9974bc49befb14d9513b47.zip
Added controlled conversions to char* instead of automatic ascii conversions.
The definition of -UTQT_NO_ASCII_CAST is no longer needed. Signed-off-by: Slávek Banko <[email protected]> (cherry picked from commit e543ebc9363bb746a042577f314240af305e07b5)
Diffstat (limited to 'src/networkinterface.cpp')
-rw-r--r--src/networkinterface.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/networkinterface.cpp b/src/networkinterface.cpp
index 25d01eb..b3fae36 100644
--- a/src/networkinterface.cpp
+++ b/src/networkinterface.cpp
@@ -379,7 +379,7 @@ TQString NetworkInterface::getGatewayOfDefaultInterface()
while ( !stream.atEnd() )
{
line = stream.readLine(); // line of text excluding '\n' and replace all white chars with one blank
- std::cout << "line: \"" << line << "\"" << "\n";
+ std::cout << "line: \"" << line.local8Bit() << "\"" << "\n";
if (line.simplifyWhiteSpace().section( ' ', 1, 1 ) == "00000000" )
{
struct sockaddr_in name;
@@ -436,7 +436,7 @@ bool NetworkInterface::inSameNetwork(TQString ip1,TQString Netmask1,TQString ip2
}
else
{
- std::cout << "ip1: " << ip1.section( '.', 0, 2 ) << " , ip2: " << ip2.section( '.', 0, 2 ) << std::endl;
+ std::cout << "ip1: " << ip1.section( '.', 0, 2 ).local8Bit() << " , ip2: " << ip2.section( '.', 0, 2 ).local8Bit() << std::endl;
if (ip1.section( '.', 0, 2 ) == ip2.section( '.', 0, 2 ))
{
if (Netmask1 == Netmask2)