diff options
author | George Hazan <george.hazan@gmail.com> | 2013-10-03 22:25:13 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2013-10-03 22:25:13 +0000 |
commit | 67e460ae2bf43109b9095c518cd2ede4e043e202 (patch) | |
tree | d4b6afb98a75fa4142b2980b792e92ee8f8fc11a /protocols/JabberG/src/jabber_byte.cpp | |
parent | 784c2757e8c791b4c76a6e739f08b0fb92ec093a (diff) |
ptrT/A/W is used everywhere instead of DBVARIANT to read database strings
git-svn-id: http://svn.miranda-ng.org/main/trunk@6322 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/JabberG/src/jabber_byte.cpp')
-rw-r--r-- | protocols/JabberG/src/jabber_byte.cpp | 18 |
1 files changed, 4 insertions, 14 deletions
diff --git a/protocols/JabberG/src/jabber_byte.cpp b/protocols/JabberG/src/jabber_byte.cpp index f0e2fcf91a..e18ae8ab7a 100644 --- a/protocols/JabberG/src/jabber_byte.cpp +++ b/protocols/JabberG/src/jabber_byte.cpp @@ -141,11 +141,8 @@ void JabberByteSendConnection(HANDLE hConn, DWORD /*dwRemoteIP*/, void* extra) void CJabberProto::ByteSendThread(JABBER_BYTE_TRANSFER *jbt)
{
- char* localAddr = NULL;
- DBVARIANT dbv;
TCHAR szPort[8];
HANDLE hEvent = NULL;
- TCHAR *proxyJid;
CJabberIqInfo *pInfo = NULL;
int nIqId = 0;
@@ -154,12 +151,7 @@ void CJabberProto::ByteSendThread(JABBER_BYTE_TRANSFER *jbt) BOOL bDirect = m_options.BsDirect;
if (m_options.BsProxyManual) {
- proxyJid = NULL;
- if ( !getString("BsProxyServer", &dbv)) {
- proxyJid = mir_a2t(dbv.pszVal);
- db_free(&dbv);
- }
-
+ ptrT proxyJid( getTStringA("BsProxyServer"));
if (proxyJid) {
jbt->bProxyDiscovered = FALSE;
jbt->szProxyHost = NULL;
@@ -198,10 +190,9 @@ void CJabberProto::ByteSendThread(JABBER_BYTE_TRANSFER *jbt) HXML query = iq << XQUERY(JABBER_FEAT_BYTESTREAMS) << XATTR(_T("sid"), jbt->sid);
if (bDirect) {
- if (m_options.BsDirectManual) {
- if ( !getString("BsDirectAddr", &dbv))
- localAddr = dbv.pszVal;
- }
+ ptrA localAddr;
+ if (m_options.BsDirectManual)
+ localAddr = getStringA("BsDirectAddr");
NETLIBBIND nlb = {0};
nlb.cbSize = sizeof(NETLIBBIND);
@@ -232,7 +223,6 @@ void CJabberProto::ByteSendThread(JABBER_BYTE_TRANSFER *jbt) query << XCHILD(_T("streamhost")) << XATTR(_T("jid"), m_ThreadInfo->fullJID) << XATTR(_T("host"), _A2T(ihaddr->szIp[i])) << XATTRI(_T("port"), nlb.wPort);
mir_free(ihaddr);
- mir_free(localAddr);
}
if (jbt->bProxyDiscovered)
|