summaryrefslogtreecommitdiff
path: root/protocols/Twitter/src/connection.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2013-10-11 14:01:25 +0000
committerGeorge Hazan <george.hazan@gmail.com>2013-10-11 14:01:25 +0000
commit773421e8ba17637d994088c393d406226b516a30 (patch)
tree130c0bf529e30f493ae4f2abbe1230d31fecdeed /protocols/Twitter/src/connection.cpp
parent3fc8b6f686262e8a595fc10b2bd947526ca77bdc (diff)
- m_hNetlibUser moved to PROTO_INTERFACE;
- unified protocol loggers git-svn-id: http://svn.miranda-ng.org/main/trunk@6435 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Twitter/src/connection.cpp')
-rw-r--r--protocols/Twitter/src/connection.cpp144
1 files changed, 72 insertions, 72 deletions
diff --git a/protocols/Twitter/src/connection.cpp b/protocols/Twitter/src/connection.cpp
index 0af2eb2e15..0d86488993 100644
--- a/protocols/Twitter/src/connection.cpp
+++ b/protocols/Twitter/src/connection.cpp
@@ -21,7 +21,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
void CALLBACK TwitterProto::APC_callback(ULONG_PTR p)
{
- reinterpret_cast<TwitterProto*>(p)->LOG( _T("***** Executing APC"));
+ reinterpret_cast<TwitterProto*>(p)->debugLogA( _T("***** Executing APC"));
}
template<typename T>
@@ -48,16 +48,16 @@ inline static INT_PTR db_pod_set(HANDLE hContact,const char *module,const char *
void TwitterProto::SignOn(void*)
{
- LOG( _T("***** Beginning SignOn process"));
+ debugLogA( _T("***** Beginning SignOn process"));
WaitForSingleObject(&signon_lock_,INFINITE);
// Kill the old thread if it's still around
// this doesn't seem to work.. should we wait infinitely?
if(hMsgLoop_)
{
- LOG( _T("***** Requesting MessageLoop to exit"));
+ debugLogA( _T("***** Requesting MessageLoop to exit"));
QueueUserAPC(APC_callback,hMsgLoop_,(ULONG_PTR)this);
- LOG( _T("***** Waiting for old MessageLoop to exit"));
+ debugLogA( _T("***** Waiting for old MessageLoop to exit"));
//WaitForSingleObject(hMsgLoop_,INFINITE);
WaitForSingleObject(hMsgLoop_,180000);
CloseHandle(hMsgLoop_);
@@ -72,12 +72,12 @@ void TwitterProto::SignOn(void*)
}
ReleaseMutex(signon_lock_);
- LOG( _T("***** SignOn complete"));
+ debugLogA( _T("***** SignOn complete"));
}
bool TwitterProto::NegotiateConnection()
{
- LOG( _T("***** Negotiating connection with Twitter"));
+ debugLogA( _T("***** Negotiating connection with Twitter"));
disconnectionCount = 0;
// saving the current status to a temp var
@@ -94,28 +94,28 @@ bool TwitterProto::NegotiateConnection()
if (!dbTOK) {
oauthToken = dbv.pwszVal;
db_free(&dbv);
- //WLOG("**NegotiateConnection - we have an oauthToken already in the db - %s", oauthToken);
+ //debugLogW("**NegotiateConnection - we have an oauthToken already in the db - %s", oauthToken);
}
INT_PTR dbTOKSec = db_get_ws(0,m_szModuleName,TWITTER_KEY_OAUTH_TOK_SECRET,&dbv);
if (!dbTOKSec) {
oauthTokenSecret = dbv.pwszVal;
db_free(&dbv);
- //WLOG("**NegotiateConnection - we have an oauthTokenSecret already in the db - %s", oauthTokenSecret);
+ //debugLogW("**NegotiateConnection - we have an oauthTokenSecret already in the db - %s", oauthTokenSecret);
}
INT_PTR dbName = db_get_s(0,m_szModuleName,TWITTER_KEY_NICK,&dbv);
if (!dbName) {
screenName = dbv.pszVal;
db_free(&dbv);
- //WLOG("**NegotiateConnection - we have a username already in the db - %s", screenName);
+ //debugLogW("**NegotiateConnection - we have a username already in the db - %s", screenName);
}
else {
dbName = db_get_s(0,m_szModuleName,TWITTER_KEY_UN,&dbv);
if (!dbName) {
screenName = dbv.pszVal;
db_set_s(0,m_szModuleName,TWITTER_KEY_NICK,dbv.pszVal);
- //WLOG("**NegotiateConnection - we have a username already in the db - %s", screenName);
+ //debugLogW("**NegotiateConnection - we have a username already in the db - %s", screenName);
}
db_free(&dbv);
}
@@ -131,35 +131,35 @@ bool TwitterProto::NegotiateConnection()
if((oauthToken.size() <= 1) || (oauthTokenSecret.size() <= 1)) {
// first, reset all the keys so we can start fresh
resetOAuthKeys();
- LOG( _T("**NegotiateConnection - Reset OAuth Keys"));
+ debugLogA( _T("**NegotiateConnection - Reset OAuth Keys"));
//twit_.set_credentials(ConsumerKey, ConsumerSecret, oauthAccessToken, oauthAccessTokenSecret, L"", false);
// i think i was doin the wrong thing here.. i was setting the credentials as oauthAccessToken instead of oauthToken
// have to test..
- LOG( _T("**NegotiateConnection - Setting Consumer Keys..."));
- /*WLOG("**NegotiateConnection - sending set_cred: consumerKey is %s", ConsumerKey);
- WLOG("**NegotiateConnection - sending set_cred: consumerSecret is %s", ConsumerSecret);
- WLOG("**NegotiateConnection - sending set_cred: oauthToken is %s", oauthToken);
- WLOG("**NegotiateConnection - sending set_cred: oauthTokenSecret is %s", oauthTokenSecret);
- LOG("**NegotiateConnection - sending set_cred: no pin");*/
+ debugLogA( _T("**NegotiateConnection - Setting Consumer Keys..."));
+ /*debugLogW("**NegotiateConnection - sending set_cred: consumerKey is %s", ConsumerKey);
+ debugLogW("**NegotiateConnection - sending set_cred: consumerSecret is %s", ConsumerSecret);
+ debugLogW("**NegotiateConnection - sending set_cred: oauthToken is %s", oauthToken);
+ debugLogW("**NegotiateConnection - sending set_cred: oauthTokenSecret is %s", oauthTokenSecret);
+ debugLogA("**NegotiateConnection - sending set_cred: no pin");*/
twit_.set_credentials("", ConsumerKey, ConsumerSecret, oauthToken, oauthTokenSecret, L"", false);
- LOG( _T("**NegotiateConnection - Requesting oauthTokens"));
+ debugLogA( _T("**NegotiateConnection - Requesting oauthTokens"));
http::response resp = twit_.request_token();
//wstring rdata_WSTR(resp.data.length(),L' ');
//std::copy(resp.data.begin(), resp.data.end(), rdata_WSTR.begin());
wstring rdata_WSTR = UTF8ToWide(resp.data);
- //WLOG("**NegotiateConnection - REQUEST TOKEN IS %s", rdata_WSTR);
+ //debugLogW("**NegotiateConnection - REQUEST TOKEN IS %s", rdata_WSTR);
OAuthParameters response = twit_.ParseQueryString(rdata_WSTR);
oauthToken = response[L"oauth_token"];
oauthTokenSecret = response[L"oauth_token_secret"];
- //WLOG("**NegotiateConnection - oauthToken is %s", oauthToken);
- //WLOG("**NegotiateConnection - oauthTokenSecret is %s", oauthTokenSecret);
+ //debugLogW("**NegotiateConnection - oauthToken is %s", oauthToken);
+ //debugLogW("**NegotiateConnection - oauthTokenSecret is %s", oauthTokenSecret);
if (oauthToken.length() < 1) {
ShowPopup("OAuth Tokens not received, check your internet connection?", 1);
- LOG( _T("**NegotiateConnection - OAuth tokens not received, stopping before we open the web browser.."));
+ debugLogA( _T("**NegotiateConnection - OAuth tokens not received, stopping before we open the web browser.."));
return false;
}
@@ -171,7 +171,7 @@ bool TwitterProto::NegotiateConnection()
wchar_t buf[1024] = {};
mir_snwprintf(buf, SIZEOF(buf), AuthorizeUrl.c_str(), oauthToken.c_str());
- WLOG( _T("**NegotiateConnection - Launching %s"), buf);
+ debugLogW( _T("**NegotiateConnection - Launching %s"), buf);
ShellExecute(NULL, L"open", buf, NULL, NULL, SW_SHOWNORMAL);
ShowPinDialog();
@@ -193,9 +193,9 @@ bool TwitterProto::NegotiateConnection()
// this bit is saying "if we have found the db key, but it contains no data, then set dbTOK to 1"
if (oauthAccessToken.size() > 1) {
realAccessTok = true;
- //WLOG("**NegotiateConnection - we have an oauthAccessToken already in the db - %s", oauthAccessToken);
+ //debugLogW("**NegotiateConnection - we have an oauthAccessToken already in the db - %s", oauthAccessToken);
}
- else { LOG( _T("**NegotiateConnection - oauthAccesToken too small? this is.. weird.")); }
+ else { debugLogA( _T("**NegotiateConnection - oauthAccesToken too small? this is.. weird.")); }
}
dbTOKSec = db_get_ws(0,m_szModuleName,TWITTER_KEY_OAUTH_ACCESS_TOK_SECRET,&dbv);
@@ -204,22 +204,22 @@ bool TwitterProto::NegotiateConnection()
db_free(&dbv);
if (oauthAccessTokenSecret.size() > 1) {
realAccessTokSecret = true;
- //WLOG("**NegotiateConnection - we have an oauthAccessTokenSecret already in the db - %s", oauthAccessTokenSecret);
+ //debugLogW("**NegotiateConnection - we have an oauthAccessTokenSecret already in the db - %s", oauthAccessTokenSecret);
}
- else { LOG( _T("**NegotiateConnection - oauthAccessTokenSecret too small? weird")); }
+ else { debugLogA( _T("**NegotiateConnection - oauthAccessTokenSecret too small? weird")); }
}
if (!realAccessTok || !realAccessTokSecret) { // if we don't have one of these beasties then lets go get 'em!
wstring pin;
- LOG( _T("**NegotiateConnection - either the accessToken or accessTokenSecret was not there.."));
+ debugLogA( _T("**NegotiateConnection - either the accessToken or accessTokenSecret was not there.."));
if (!db_get_ws(0,m_szModuleName,TWITTER_KEY_OAUTH_PIN,&dbv)) {
pin = dbv.pwszVal;
- //WLOG("**NegotiateConnection - we have an pin already in the db - %s", pin);
+ //debugLogW("**NegotiateConnection - we have an pin already in the db - %s", pin);
db_free(&dbv);
}
else {
ShowPopup(TranslateT("OAuth variables are out of sequence, they have been reset. Please reconnect and reauthorize Miranda to Twitter.com (do the PIN stuff again)"));
- LOG( _T("**NegotiateConnection - We don't have a PIN? this doesn't make sense. Resetting OAuth keys and setting offline."));
+ debugLogA( _T("**NegotiateConnection - We don't have a PIN? this doesn't make sense. Resetting OAuth keys and setting offline."));
resetOAuthKeys();
ProtoBroadcastAck(0,ACKTYPE_STATUS,ACKRESULT_FAILED,(HANDLE)old_status,m_iStatus);
@@ -232,19 +232,19 @@ bool TwitterProto::NegotiateConnection()
return false;
}
- LOG( _T("**NegotiateConnection - Setting Consumer Keys and PIN..."));
- /*WLOG("**NegotiateConnection - sending set_cred: consumerKey is %s", ConsumerKey);
- WLOG("**NegotiateConnection - sending set_cred: consumerSecret is %s", ConsumerSecret);
- WLOG("**NegotiateConnection - sending set_cred: oauthToken is %s", oauthToken);
- WLOG("**NegotiateConnection - sending set_cred: oauthTokenSecret is %s", oauthTokenSecret);
- WLOG("**NegotiateConnection - sending set_cred: pin is %s", pin);*/
+ debugLogA( _T("**NegotiateConnection - Setting Consumer Keys and PIN..."));
+ /*debugLogW("**NegotiateConnection - sending set_cred: consumerKey is %s", ConsumerKey);
+ debugLogW("**NegotiateConnection - sending set_cred: consumerSecret is %s", ConsumerSecret);
+ debugLogW("**NegotiateConnection - sending set_cred: oauthToken is %s", oauthToken);
+ debugLogW("**NegotiateConnection - sending set_cred: oauthTokenSecret is %s", oauthTokenSecret);
+ debugLogW("**NegotiateConnection - sending set_cred: pin is %s", pin);*/
twit_.set_credentials("", ConsumerKey, ConsumerSecret, oauthToken, oauthTokenSecret, pin, false);
- LOG( _T("**NegotiateConnection - requesting access tokens..."));
+ debugLogA( _T("**NegotiateConnection - requesting access tokens..."));
http::response accessResp = twit_.request_access_tokens();
if (accessResp.code != 200) {
- LOG( _T("**NegotiateConnection - Failed to get Access Tokens, HTTP response code is: %d"), accessResp.code);
+ debugLogA( _T("**NegotiateConnection - Failed to get Access Tokens, HTTP response code is: %d"), accessResp.code);
ShowPopup(TranslateT("Failed to get Twitter Access Tokens, please go offline and try again. If this keeps happening, check your internet connection."));
resetOAuthKeys();
@@ -259,21 +259,21 @@ bool TwitterProto::NegotiateConnection()
return false;
}
else {
- LOG( _T("**NegotiateConnection - Successfully retrieved Access Tokens"));
+ debugLogA( _T("**NegotiateConnection - Successfully retrieved Access Tokens"));
wstring rdata_WSTR2 = UTF8ToWide(accessResp.data);
- //WLOG("**NegotiateConnection - accessToken STring is %s", rdata_WSTR2);
+ //debugLogW("**NegotiateConnection - accessToken STring is %s", rdata_WSTR2);
OAuthParameters accessTokenParameters = twit_.ParseQueryString(rdata_WSTR2);
oauthAccessToken = accessTokenParameters[L"oauth_token"];
- //WLOG("**NegotiateConnection - oauthAccessToken is %s", oauthAccessToken);
+ //debugLogW("**NegotiateConnection - oauthAccessToken is %s", oauthAccessToken);
oauthAccessTokenSecret = accessTokenParameters[L"oauth_token_secret"];
- //WLOG("**NegotiateConnection - oauthAccessTokenSecret is %s", oauthAccessTokenSecret);
+ //debugLogW("**NegotiateConnection - oauthAccessTokenSecret is %s", oauthAccessTokenSecret);
screenName = WideToUTF8(accessTokenParameters[L"screen_name"]);
- LOG( _T("**NegotiateConnection - screen name is %s"), screenName.c_str());
+ debugLogA( _T("**NegotiateConnection - screen name is %s"), screenName.c_str());
//save em
db_set_ws(0,m_szModuleName,TWITTER_KEY_OAUTH_ACCESS_TOK,oauthAccessToken.c_str());
@@ -301,16 +301,16 @@ bool TwitterProto::NegotiateConnection()
db_free(&dbv);
}
- LOG( _T("**NegotiateConnection - Setting Consumer Keys and verifying creds..."));
- /*WLOG("**NegotiateConnection - sending set_cred: consumerKey is %s", ConsumerKey);
- WLOG("**NegotiateConnection - sending set_cred: consumerSecret is %s", ConsumerSecret);
- WLOG("**NegotiateConnection - sending set_cred: oauthAccessToken is %s", oauthAccessToken);
- WLOG("**NegotiateConnection - sending set_cred: oauthAccessTokenSecret is %s", oauthAccessTokenSecret);
- LOG("**NegotiateConnection - sending set_cred: no pin");*/
+ debugLogA( _T("**NegotiateConnection - Setting Consumer Keys and verifying creds..."));
+ /*debugLogW("**NegotiateConnection - sending set_cred: consumerKey is %s", ConsumerKey);
+ debugLogW("**NegotiateConnection - sending set_cred: consumerSecret is %s", ConsumerSecret);
+ debugLogW("**NegotiateConnection - sending set_cred: oauthAccessToken is %s", oauthAccessToken);
+ debugLogW("**NegotiateConnection - sending set_cred: oauthAccessTokenSecret is %s", oauthAccessTokenSecret);
+ debugLogA("**NegotiateConnection - sending set_cred: no pin");*/
if (screenName.empty()) {
ShowPopup(TranslateT("You're missing the Nick key in the database. This isn't really a big deal, but you'll notice some minor quirks (self contact in list, no group chat outgoing message highlighting, etc). To fix it either add it manually or reset your twitter account in the miranda account options"));
- LOG( _T("**NegotiateConnection - Missing the Nick key in the database. Everything will still work, but it's nice to have"));
+ debugLogA( _T("**NegotiateConnection - Missing the Nick key in the database. Everything will still work, but it's nice to have"));
}
bool success;
@@ -322,7 +322,7 @@ bool TwitterProto::NegotiateConnection()
if(!success) {
//ShowPopup(TranslateT("Something went wrong with authorisation, OAuth keys have been reset. Please try to reconnect. If problems persist, please se your doctor"));
- LOG( _T("**NegotiateConnection - Verifying credentials failed! No internet maybe?"));
+ debugLogA( _T("**NegotiateConnection - Verifying credentials failed! No internet maybe?"));
//resetOAuthKeys();
ProtoBroadcastAck(0,ACKTYPE_STATUS,ACKRESULT_FAILED,(HANDLE)old_status,m_iStatus);
@@ -345,7 +345,7 @@ bool TwitterProto::NegotiateConnection()
void TwitterProto::MessageLoop(void*)
{
- LOG( _T("***** Entering Twitter::MessageLoop"));
+ debugLogA( _T("***** Entering Twitter::MessageLoop"));
since_id_ = db_pod_get<twitter_id>(0,m_szModuleName,TWITTER_KEY_SINCEID,0);
dm_since_id_ = db_pod_get<twitter_id>(0,m_szModuleName,TWITTER_KEY_DMSINCEID,0);
@@ -384,10 +384,10 @@ void TwitterProto::MessageLoop(void*)
if(m_iStatus != ID_STATUS_ONLINE)
break;
- LOG( _T("***** TwitterProto::MessageLoop going to sleep..."));
+ debugLogA( _T("***** TwitterProto::MessageLoop going to sleep..."));
if(SleepEx(poll_rate*1000,true) == WAIT_IO_COMPLETION)
break;
- LOG( _T("***** TwitterProto::MessageLoop waking up..."));
+ debugLogA( _T("***** TwitterProto::MessageLoop waking up..."));
popups = true;
}
@@ -396,7 +396,7 @@ void TwitterProto::MessageLoop(void*)
ScopedLock s(twitter_lock_);
twit_.set_credentials("",L"",L"",L"",L"",L"", false);
}
- LOG( _T("***** Exiting TwitterProto::MessageLoop"));
+ debugLogA( _T("***** Exiting TwitterProto::MessageLoop"));
}
struct update_avatar
@@ -429,17 +429,17 @@ void TwitterProto::UpdateAvatarWorker(void *p)
ai.format = ProtoGetAvatarFormat(filename.c_str());
if (ai.format == PA_FORMAT_UNKNOWN) {
- LOG( _T("***** Update avatar: Terminated for this contact, extension format unknown for %s"), data->url.c_str());
+ debugLogA( _T("***** Update avatar: Terminated for this contact, extension format unknown for %s"), data->url.c_str());
return; // lets just ignore unknown formats... if not it crashes miranda. should probably speak to borkra about this.
}
_tcsncpy(ai.filename,filename.c_str(),MAX_PATH); // puts the local file name in the avatar struct, to a max of 260 chars (as of now)
- LOG( _T("***** Updating avatar: %s"), data->url.c_str());
+ debugLogA( _T("***** Updating avatar: %s"), data->url.c_str());
WaitForSingleObjectEx(avatar_lock_,INFINITE,true);
if(CallService(MS_SYSTEM_TERMINATED,0,0)) // if miranda is shutting down...
{
- LOG( _T("***** Terminating avatar update early: %s"),data->url.c_str());
+ debugLogA( _T("***** Terminating avatar update early: %s"),data->url.c_str());
return;
}
@@ -451,7 +451,7 @@ void TwitterProto::UpdateAvatarWorker(void *p)
else
ProtoBroadcastAck(data->hContact,ACKTYPE_AVATAR,ACKRESULT_FAILED, &ai,0);
ReleaseMutex(avatar_lock_);
- LOG( _T("***** Done avatar: %s"),data->url.c_str());
+ debugLogA( _T("***** Done avatar: %s"),data->url.c_str());
}
void TwitterProto::UpdateAvatar(HANDLE hContact,const std::string &url,bool force)
@@ -460,7 +460,7 @@ void TwitterProto::UpdateAvatar(HANDLE hContact,const std::string &url,bool forc
if( !force && (!db_get_s(hContact,m_szModuleName,TWITTER_KEY_AV_URL,&dbv) && url == dbv.pszVal))
{
- LOG( _T("***** Avatar already up-to-date: %s"), url.c_str());
+ debugLogA( _T("***** Avatar already up-to-date: %s"), url.c_str());
}
else
{
@@ -497,21 +497,21 @@ void TwitterProto::UpdateFriends()
UpdateAvatar(hContact,i->profile_image_url);
}
disconnectionCount = 0;
- LOG( _T("***** Friends list updated"));
+ debugLogA( _T("***** Friends list updated"));
}
catch(const bad_response &)
{
++disconnectionCount;
- LOG( _T("***** UpdateFriends - Bad response from server, this has happened %d time(s)"), disconnectionCount);
+ debugLogA( _T("***** UpdateFriends - Bad response from server, this has happened %d time(s)"), disconnectionCount);
if (disconnectionCount > 2) {
- LOG( _T("***** UpdateFriends - Too many bad responses from the server, signing off"));
+ debugLogA( _T("***** UpdateFriends - Too many bad responses from the server, signing off"));
SetStatus(ID_STATUS_OFFLINE);
}
}
catch(const std::exception &e)
{
ShowPopup( (std::string("While updating friends list, an error occurred: ")+e.what()).c_str());
- LOG( _T("***** Error updating friends list: %s"), e.what());
+ debugLogA( _T("***** Error updating friends list: %s"), e.what());
}
}
@@ -588,14 +588,14 @@ void TwitterProto::UpdateStatuses(bool pre_read, bool popups, bool tweetToMsg)
db_pod_set(0,m_szModuleName,TWITTER_KEY_SINCEID,since_id_);
disconnectionCount = 0;
- LOG( _T("***** Status messages updated"));
+ debugLogA( _T("***** Status messages updated"));
}
catch(const bad_response &)
{
++disconnectionCount;
- LOG( _T("***** UpdateStatuses - Bad response from server, this has happened %d time(s)"), disconnectionCount);
+ debugLogA( _T("***** UpdateStatuses - Bad response from server, this has happened %d time(s)"), disconnectionCount);
if (disconnectionCount > 2) {
- LOG( _T("***** UpdateStatuses - Too many bad responses from the server, signing off"));
+ debugLogA( _T("***** UpdateStatuses - Too many bad responses from the server, signing off"));
SetStatus(ID_STATUS_OFFLINE);
}
}
@@ -603,7 +603,7 @@ void TwitterProto::UpdateStatuses(bool pre_read, bool popups, bool tweetToMsg)
{
ShowPopup( (std::string("While updating status messages, an error occurred: ")
+e.what()).c_str());
- LOG( _T("***** Error updating status messages: %s"), e.what());
+ debugLogA( _T("***** Error updating status messages: %s"), e.what());
}
}
@@ -633,21 +633,21 @@ void TwitterProto::UpdateMessages(bool pre_read)
db_pod_set(0,m_szModuleName,TWITTER_KEY_DMSINCEID,dm_since_id_);
disconnectionCount = 0;
- LOG( _T("***** Direct messages updated"));
+ debugLogA( _T("***** Direct messages updated"));
}
catch(const bad_response &)
{
++disconnectionCount;
- LOG( _T("***** UpdateMessages - Bad response from server, this has happened %d time(s)"), disconnectionCount);
+ debugLogA( _T("***** UpdateMessages - Bad response from server, this has happened %d time(s)"), disconnectionCount);
if (disconnectionCount > 2) {
- LOG( _T("***** UpdateMessages - Too many bad responses from the server, signing off"));
+ debugLogA( _T("***** UpdateMessages - Too many bad responses from the server, signing off"));
SetStatus(ID_STATUS_OFFLINE);
}
}
catch(const std::exception &e)
{
ShowPopup( (std::string("While updating direct messages, an error occurred: ")+e.what()).c_str());
- LOG( _T("***** Error updating direct messages: %s"), e.what());
+ debugLogA( _T("***** Error updating direct messages: %s"), e.what());
}
}