diff options
author | George Hazan <george.hazan@gmail.com> | 2016-07-27 14:23:31 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2016-07-27 14:23:31 +0000 |
commit | 2f261839b60692e33d0e160344d0d636d49c90ba (patch) | |
tree | 187921722698b681d29df3f6e60fb18394a5e9d5 /plugins/ConnectionNotify/src/netstat.cpp | |
parent | 2e931a0b2780587d85f3902468c935f5adba70c8 (diff) |
less TCHARs
git-svn-id: http://svn.miranda-ng.org/main/trunk@17138 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/ConnectionNotify/src/netstat.cpp')
-rw-r--r-- | plugins/ConnectionNotify/src/netstat.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/plugins/ConnectionNotify/src/netstat.cpp b/plugins/ConnectionNotify/src/netstat.cpp index a9827bf7f4..663e22a16e 100644 --- a/plugins/ConnectionNotify/src/netstat.cpp +++ b/plugins/ConnectionNotify/src/netstat.cpp @@ -41,14 +41,14 @@ struct CONNECTION *GetConnectionsTable() if (pTcpTable->table[i].dwLocalAddr) { IpAddr.S_un.S_addr = (ULONG)pTcpTable->table[i].dwLocalAddr; //_snprintf(newConn->strIntIp,_countof(newConn->strIntIp),"%d.%d.%d.%d",IpAddr.S_un.S_un_b.s_b1,IpAddr.S_un.S_un_b.s_b2,IpAddr.S_un.S_un_b.s_b3,IpAddr.S_un.S_un_b.s_b4); - wchar_t *strIntIp = mir_a2t(inet_ntoa(IpAddr)); + wchar_t *strIntIp = mir_a2u(inet_ntoa(IpAddr)); wcsncpy(newConn->strIntIp, strIntIp, _countof(newConn->strIntIp) - 1); mir_free(strIntIp); } if (pTcpTable->table[i].dwRemoteAddr) { IpAddr.S_un.S_addr = (u_long)pTcpTable->table[i].dwRemoteAddr; - wchar_t *strExtIp = mir_a2t(inet_ntoa(IpAddr)); + wchar_t *strExtIp = mir_a2u(inet_ntoa(IpAddr)); wcsncpy(newConn->strExtIp, strExtIp, _countof(newConn->strExtIp) - 1); mir_free(strExtIp); } @@ -126,8 +126,8 @@ void deleteConnectionsTable(struct CONNECTION *head) struct CONNECTION *searchConnection(struct CONNECTION *head, wchar_t *intIp, wchar_t *extIp, int intPort, int extPort, int state) { for (struct CONNECTION *cur = head; cur != NULL; cur = cur->next) { - if (mir_tstrcmp(cur->strIntIp, intIp) == 0 && - mir_tstrcmp(cur->strExtIp, extIp) == 0 && + if (mir_wstrcmp(cur->strIntIp, intIp) == 0 && + mir_wstrcmp(cur->strExtIp, extIp) == 0 && cur->intExtPort == extPort && cur->intIntPort == intPort && cur->state == state) @@ -140,7 +140,7 @@ void getDnsName(wchar_t *strIp, wchar_t *strHostName, size_t len) { in_addr iaHost; - char *szStrIP = mir_t2a(strIp); + char *szStrIP = mir_u2a(strIp); iaHost.s_addr = inet_addr(szStrIP); mir_free(szStrIP); hostent *h = gethostbyaddr((char *)&iaHost, sizeof(struct in_addr), AF_INET); |