summaryrefslogtreecommitdiffstats
path: root/src/torkview.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/torkview.cpp')
-rw-r--r--src/torkview.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/torkview.cpp b/src/torkview.cpp
index e03fe92..ff76276 100644
--- a/src/torkview.cpp
+++ b/src/torkview.cpp
@@ -933,12 +933,12 @@ TQString torkView::parseStreamPort(const TQString &str_port)
TQString path = "/proc/" +*it+"/fd";
- if ((pdir = opendir((const char*)path)) == NULL)
+ if ((pdir = opendir(path.local8Bit())) == NULL)
continue;
while ((pde = readdir(pdir)) != NULL) {
- snprintf(fdpath, MAX_PROC_STR_LEN, "/proc/%s/fd/%s", (const char*)*it, pde->d_name);
+ snprintf(fdpath, MAX_PROC_STR_LEN, "/proc/%s/fd/%s", (*it).local8Bit().data(), pde->d_name);
fdpath[MAX_PROC_STR_LEN - 1] = '\0';
int len = readlink(fdpath, lbuf, MAX_PROC_STR_LEN);
@@ -1013,12 +1013,12 @@ void torkView::ORStatusUpdated(const TQString &ORID, const TQString &status)
if (tmpstatus.contains("closed") || tmpstatus.contains("failed")){
delete ORline;
- if (entryGuards[ORID])
+ if (!entryGuards[ORID].isEmpty())
entryGuards.remove(ORID);
return;
}
- if (entryGuards[ORID]){
+ if (!entryGuards[ORID].isEmpty()){
guardStatusUpdated(ORID, status);
return;
}
@@ -1333,10 +1333,10 @@ void torkView::serverStatusUpdated(const TQString &ip,const TQString &fp,
#endif
if (gi){
- country_id = GeoIP_id_by_name(gi, ip);
+ country_id = GeoIP_id_by_name(gi, ip.latin1());
cc = GeoIP_country_code[country_id];
GeoIP_delete(gi);
-
+
if (!m_countryList.contains(country_id))
m_countryList << country_id;
}else