summaryrefslogtreecommitdiff
path: root/protocols/Gadu-Gadu
diff options
context:
space:
mode:
Diffstat (limited to 'protocols/Gadu-Gadu')
-rw-r--r--protocols/Gadu-Gadu/src/avatar.cpp6
-rw-r--r--protocols/Gadu-Gadu/src/core.cpp6
-rw-r--r--protocols/Gadu-Gadu/src/filetransfer.cpp4
-rw-r--r--protocols/Gadu-Gadu/src/gg_proto.cpp4
-rw-r--r--protocols/Gadu-Gadu/src/groupchat.cpp2
-rw-r--r--protocols/Gadu-Gadu/src/image.cpp16
-rw-r--r--protocols/Gadu-Gadu/src/import.cpp10
-rw-r--r--protocols/Gadu-Gadu/src/ownerinfo.cpp2
-rw-r--r--protocols/Gadu-Gadu/src/services.cpp4
-rw-r--r--protocols/Gadu-Gadu/src/sessions.cpp2
-rw-r--r--protocols/Gadu-Gadu/src/token.cpp4
-rw-r--r--protocols/Gadu-Gadu/src/userutils.cpp8
12 files changed, 34 insertions, 34 deletions
diff --git a/protocols/Gadu-Gadu/src/avatar.cpp b/protocols/Gadu-Gadu/src/avatar.cpp
index 1d27e336ed..c1d4936588 100644
--- a/protocols/Gadu-Gadu/src/avatar.cpp
+++ b/protocols/Gadu-Gadu/src/avatar.cpp
@@ -37,7 +37,7 @@ void GGPROTO::getAvatarFilename(MCONTACT hContact, TCHAR *pszDest, int cbLen)
else {
debugLog(_T("getAvatarFilename(): Can not create directory for avatar cache: %s. errno=%d: %s"), pszDest, errno, strerror(errno));
TCHAR error[512];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Cannot create avatars cache directory. ERROR: %d: %s\n%s"), errno, _tcserror(errno), pszDest);
+ mir_sntprintf(error, TranslateT("Cannot create avatars cache directory. ERROR: %d: %s\n%s"), errno, _tcserror(errno), pszDest);
showpopup(m_tszUserName, error, GG_POPUP_ERROR | GG_POPUP_ALLOW_MSGBOX | GG_POPUP_ONCE);
}
}
@@ -271,7 +271,7 @@ void __cdecl GGPROTO::avatarrequestthread(void*)
} else {
debugLog(_T("avatarrequestthread(): _topen file %s error. errno=%d: %s"), ai.filename, errno, strerror(errno));
TCHAR error[512];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Cannot create avatar file. ERROR: %d: %s\n%s"), errno, _tcserror(errno), ai.filename);
+ mir_sntprintf(error, TranslateT("Cannot create avatar file. ERROR: %d: %s\n%s"), errno, _tcserror(errno), ai.filename);
showpopup(m_tszUserName, error, GG_POPUP_ERROR);
}
}
@@ -363,7 +363,7 @@ void __cdecl GGPROTO::setavatarthread(void *param)
if (file_fd == -1) {
debugLogA("setavatarthread(): Failed to open avatar file errno=%d: %s.", errno, strerror(errno));
TCHAR error[512];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Cannot open avatar file. ERROR: %d: %s\n%s"), errno, _tcserror(errno), szFilename);
+ mir_sntprintf(error, TranslateT("Cannot open avatar file. ERROR: %d: %s\n%s"), errno, _tcserror(errno), szFilename);
showpopup(m_tszUserName, error, GG_POPUP_ERROR);
mir_free(szFilename);
int prevType = getByte(GG_KEY_AVATARTYPEPREV, -1);
diff --git a/protocols/Gadu-Gadu/src/core.cpp b/protocols/Gadu-Gadu/src/core.cpp
index 70f393d3e9..f37120f268 100644
--- a/protocols/Gadu-Gadu/src/core.cpp
+++ b/protocols/Gadu-Gadu/src/core.cpp
@@ -361,7 +361,7 @@ void __cdecl GGPROTO::mainthread(void *)
if (!(p.external_addr = gg_dnslookup(this, dbv.pszVal))) {
TCHAR error[128];
TCHAR* forwardHostT = mir_a2t(dbv.pszVal);
- mir_sntprintf(error, SIZEOF(error), TranslateT("External direct connections hostname %s is invalid. Disabling external host forwarding."), forwardHostT);
+ mir_sntprintf(error, TranslateT("External direct connections hostname %s is invalid. Disabling external host forwarding."), forwardHostT);
mir_free(forwardHostT);
showpopup(m_tszUserName, error, GG_POPUP_WARNING | GG_POPUP_ALLOW_MSGBOX);
}
@@ -392,7 +392,7 @@ retry:
{
TCHAR error[128];
TCHAR* hostnameT = mir_a2t(hosts[hostnum].hostname);
- mir_sntprintf(error, SIZEOF(error), TranslateT("Server hostname %s is invalid. Using default hostname provided by the network."), hostnameT);
+ mir_sntprintf(error, TranslateT("Server hostname %s is invalid. Using default hostname provided by the network."), hostnameT);
mir_free(hostnameT);
showpopup(m_tszUserName, error, GG_POPUP_WARNING | GG_POPUP_ALLOW_MSGBOX);
}
@@ -423,7 +423,7 @@ retry:
}
}
if (!perror) {
- mir_sntprintf(error, SIZEOF(error), TranslateT("Connection cannot be established. errno=%d: %s"),errno, strerror(errno));
+ mir_sntprintf(error, TranslateT("Connection cannot be established. errno=%d: %s"),errno, strerror(errno));
perror = error;
}
debugLogA("mainthread() (%x): %s", this, perror);
diff --git a/protocols/Gadu-Gadu/src/filetransfer.cpp b/protocols/Gadu-Gadu/src/filetransfer.cpp
index 23f56f4a5b..61d8ab6014 100644
--- a/protocols/Gadu-Gadu/src/filetransfer.cpp
+++ b/protocols/Gadu-Gadu/src/filetransfer.cpp
@@ -677,7 +677,7 @@ HANDLE GGPROTO::dccfileallow(HANDLE hTransfer, const TCHAR* szPath)
{
debugLogA("dccfileallow(): Failed to create file \"%s\". errno=%d: %s", fileName, errno, strerror(errno));
TCHAR error[512];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Cannot create transfer file. ERROR: %d: %s (dcc)\n%s"), errno, _tcserror(errno), szPath);
+ mir_sntprintf(error, TranslateT("Cannot create transfer file. ERROR: %d: %s (dcc)\n%s"), errno, _tcserror(errno), szPath);
showpopup(m_tszUserName, error, GG_POPUP_ERROR);
ProtoBroadcastAck((MCONTACT)dcc->contact, ACKTYPE_FILE, ACKRESULT_FAILED, dcc, 0);
// Free transfer
@@ -726,7 +726,7 @@ HANDLE GGPROTO::dcc7fileallow(HANDLE hTransfer, const TCHAR* szPath)
{
debugLogA("dcc7fileallow(): Failed to create file \"%s\". errno=%d: %s", fileName, errno, strerror(errno));
TCHAR error[512];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Cannot create transfer file. ERROR: %d: %s (dcc7)\n%s"), errno, _tcserror(errno), szPath);
+ mir_sntprintf(error, TranslateT("Cannot create transfer file. ERROR: %d: %s (dcc7)\n%s"), errno, _tcserror(errno), szPath);
showpopup(m_tszUserName, error, GG_POPUP_ERROR);
gg_dcc7_reject(dcc7, GG_DCC7_REJECT_USER);
ProtoBroadcastAck((MCONTACT)dcc7->contact, ACKTYPE_FILE, ACKRESULT_FAILED, dcc7, 0);
diff --git a/protocols/Gadu-Gadu/src/gg_proto.cpp b/protocols/Gadu-Gadu/src/gg_proto.cpp
index 9d0c8d4a2c..7c98ed6bc9 100644
--- a/protocols/Gadu-Gadu/src/gg_proto.cpp
+++ b/protocols/Gadu-Gadu/src/gg_proto.cpp
@@ -68,7 +68,7 @@ GGPROTO::GGPROTO(const char* pszProtoName, const TCHAR* tszUserName) :
db_set_resident(m_szModuleName, GG_KEY_AVATARREQUESTED);
TCHAR szPath[MAX_PATH];
- mir_sntprintf(szPath, SIZEOF(szPath), _T("%s\\%s\\ImageCache"), (TCHAR*)VARST( _T("%miranda_userdata%")), m_tszUserName);
+ mir_sntprintf(szPath, _T("%s\\%s\\ImageCache"), (TCHAR*)VARST( _T("%miranda_userdata%")), m_tszUserName);
hImagesFolder = FoldersRegisterCustomPathT(LPGEN("Images"), m_szModuleName, szPath, m_tszUserName);
DWORD dwVersion;
@@ -452,7 +452,7 @@ HWND GGPROTO::SearchAdvanced(HWND hwndDlg)
yearFrom = 0;
else
yearFrom = ay - yearFrom;
- mir_sntprintf(text, SIZEOF(text), _T("%d %d"), yearFrom, yearTo);
+ mir_sntprintf(text, _T("%d %d"), yearFrom, yearTo);
T2Utf age_utf8(text);
gg_pubdir50_add(req, GG_PUBDIR50_BIRTHYEAR, age_utf8);
diff --git a/protocols/Gadu-Gadu/src/groupchat.cpp b/protocols/Gadu-Gadu/src/groupchat.cpp
index 0b9b9e21e0..1a1983e4e5 100644
--- a/protocols/Gadu-Gadu/src/groupchat.cpp
+++ b/protocols/Gadu-Gadu/src/groupchat.cpp
@@ -282,7 +282,7 @@ TCHAR* GGPROTO::gc_getchat(uin_t sender, uin_t *recipients, int recipients_count
TCHAR *senderName = unknownSender ?
TranslateT("Unknown") : pcli->pfnGetContactDisplayName(getcontact(sender, 0, 0, NULL), 0);
TCHAR error[256];
- mir_sntprintf(error, SIZEOF(error), TranslateT("%s has initiated conference with %d participants (%d unknowns).\nDo you want to participate?"),
+ mir_sntprintf(error, TranslateT("%s has initiated conference with %d participants (%d unknowns).\nDo you want to participate?"),
senderName, recipients_count + 1, unknown);
chat->ignore = MessageBox(NULL, error, m_tszUserName, MB_OKCANCEL | MB_ICONEXCLAMATION) != IDOK;
}
diff --git a/protocols/Gadu-Gadu/src/image.cpp b/protocols/Gadu-Gadu/src/image.cpp
index 7fccf30251..f92c77fac1 100644
--- a/protocols/Gadu-Gadu/src/image.cpp
+++ b/protocols/Gadu-Gadu/src/image.cpp
@@ -422,9 +422,9 @@ static INT_PTR CALLBACK gg_img_dlgproc(HWND hwndDlg, UINT msg, WPARAM wParam, LP
TCHAR *szName = pcli->pfnGetContactDisplayName(dat->hContact, 0), szTitle[128];
if (dat->bReceiving)
- mir_sntprintf(szTitle, SIZEOF(szTitle), TranslateT("Image from %s"), szName);
+ mir_sntprintf(szTitle, TranslateT("Image from %s"), szName);
else
- mir_sntprintf(szTitle, SIZEOF(szTitle), TranslateT("Image for %s"), szName);
+ mir_sntprintf(szTitle, TranslateT("Image for %s"), szName);
SetWindowText(hwndDlg, szTitle);
// Store client extents
@@ -505,7 +505,7 @@ static INT_PTR CALLBACK gg_img_dlgproc(HWND hwndDlg, UINT msg, WPARAM wParam, LP
if (dat->bReceiving)
{
TCHAR szTitle[128];
- mir_sntprintf(szTitle, SIZEOF(szTitle), _T("%s (%d / %d)"), img->lpszFileName, dat->nImg, dat->nImgTotal);
+ mir_sntprintf(szTitle, _T("%s (%d / %d)"), img->lpszFileName, dat->nImg, dat->nImgTotal);
SetDlgItemText(hwndDlg, IDC_IMG_NAME, szTitle);
}
else
@@ -813,7 +813,7 @@ int GGPROTO::img_displayasmsg(MCONTACT hContact, void *img)
if (hImagesFolder == NULL || FoldersGetCustomPathT(hImagesFolder, path, MAX_PATH, _T(""))) {
TCHAR *tmpPath = Utils_ReplaceVarsT( _T("%miranda_userdata%"));
- tPathLen = mir_sntprintf(szPath, SIZEOF(szPath), _T("%s\\%s\\ImageCache"), tmpPath, m_tszUserName);
+ tPathLen = mir_sntprintf(szPath, _T("%s\\%s\\ImageCache"), tmpPath, m_tszUserName);
mir_free(tmpPath);
}
else {
@@ -828,7 +828,7 @@ int GGPROTO::img_displayasmsg(MCONTACT hContact, void *img)
} else {
debugLog(_T("img_displayasmsg(): Can not create directory for image cache: %s. errno=%d: %s"), szPath, errno, strerror(errno));
TCHAR error[512];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Cannot create image cache directory. ERROR: %d: %s\n%s"), errno, _tcserror(errno), szPath);
+ mir_sntprintf(error, TranslateT("Cannot create image cache directory. ERROR: %d: %s\n%s"), errno, _tcserror(errno), szPath);
showpopup(m_tszUserName, error, GG_POPUP_ERROR | GG_POPUP_ALLOW_MSGBOX | GG_POPUP_ONCE);
}
}
@@ -840,7 +840,7 @@ int GGPROTO::img_displayasmsg(MCONTACT hContact, void *img)
for (i = 1; ; ++i)
{
if ((res = gg_img_isexists(szPath, dat)) != -1) break;
- mir_sntprintf(szPath, SIZEOF(szPath), _T("%.*s (%u)%s"), pImgext - szPath, szPath, i, imgext);
+ mir_sntprintf(szPath, _T("%.*s (%u)%s"), pImgext - szPath, szPath, i, imgext);
}
if (res == 0) {
@@ -852,7 +852,7 @@ int GGPROTO::img_displayasmsg(MCONTACT hContact, void *img)
} else {
debugLog(_T("img_displayasmsg(): Cannot open file %s for write image. errno=%d: %s"), szPath, errno, strerror(errno));
TCHAR error[512];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Cannot save received image to file. ERROR: %d: %s\n%s"), errno, _tcserror(errno), szPath);
+ mir_sntprintf(error, TranslateT("Cannot save received image to file. ERROR: %d: %s\n%s"), errno, _tcserror(errno), szPath);
showpopup(m_tszUserName, error, GG_POPUP_ERROR);
return 0;
}
@@ -975,7 +975,7 @@ void* GGPROTO::img_loadpicture(gg_event* e, TCHAR *szFileName)
free(dat);
debugLog(_T("img_loadpicture(): fopen(\"%s\", \"rb\") failed. errno=%d: %s"), szFileName, errno, strerror(errno));
TCHAR error[512];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Cannot open image file. ERROR: %d: %s\n%s"), errno, _tcserror(errno), szFileName);
+ mir_sntprintf(error, TranslateT("Cannot open image file. ERROR: %d: %s\n%s"), errno, _tcserror(errno), szFileName);
showpopup(m_tszUserName, error, GG_POPUP_ERROR);
return NULL;
}
diff --git a/protocols/Gadu-Gadu/src/import.cpp b/protocols/Gadu-Gadu/src/import.cpp
index 2ca709ae01..b82a30418f 100644
--- a/protocols/Gadu-Gadu/src/import.cpp
+++ b/protocols/Gadu-Gadu/src/import.cpp
@@ -278,7 +278,7 @@ INT_PTR GGPROTO::import_server(WPARAM wParam, LPARAM lParam)
{
TCHAR error[128];
gg_LeaveCriticalSection(&sess_mutex, "import_server", 65, 1, "sess_mutex", 1);
- mir_sntprintf(error, SIZEOF(error), TranslateT("List cannot be imported because of error:\n\t%s (Error: %d)"), _tcserror(errno), errno);
+ mir_sntprintf(error, TranslateT("List cannot be imported because of error:\n\t%s (Error: %d)"), _tcserror(errno), errno);
MessageBox(NULL, error, m_tszUserName, MB_OK | MB_ICONSTOP);
debugLogA("import_server(): Cannot import list. errno:%d: %s", errno, strerror(errno));
}
@@ -316,7 +316,7 @@ INT_PTR GGPROTO::remove_server(WPARAM wParam, LPARAM lParam)
{
TCHAR error[128];
gg_LeaveCriticalSection(&sess_mutex, "remove_server", 66, 1, "sess_mutex", 1);
- mir_sntprintf(error, SIZEOF(error), TranslateT("List cannot be removed because of error: %s (Error: %d)"), _tcserror(errno), errno);
+ mir_sntprintf(error, TranslateT("List cannot be removed because of error: %s (Error: %d)"), _tcserror(errno), errno);
MessageBox(NULL, error, m_tszUserName, MB_OK | MB_ICONSTOP);
debugLogA("remove_server(): Cannot remove list. errno=%d: %s", errno, strerror(errno));
}
@@ -389,7 +389,7 @@ INT_PTR GGPROTO::import_text(WPARAM wParam, LPARAM lParam)
else
{
TCHAR error[256];
- mir_sntprintf(error, SIZEOF(error), TranslateT("List cannot be imported from file \"%s\" because of error:\n\t%s (Error: %d)"), str, _tcserror(errno), errno);
+ mir_sntprintf(error, TranslateT("List cannot be imported from file \"%s\" because of error:\n\t%s (Error: %d)"), str, _tcserror(errno), errno);
MessageBox(NULL, error, m_tszUserName, MB_OK | MB_ICONSTOP);
debugLog(_T("import_text(): Cannot import list from file \"%s\". errno=%d: %s"), str, errno, strerror(errno));
}
@@ -450,7 +450,7 @@ INT_PTR GGPROTO::export_text(WPARAM wParam, LPARAM lParam)
else
{
TCHAR error[128];
- mir_sntprintf(error, SIZEOF(error), TranslateT("List cannot be exported to file \"%s\" because of error:\n\t%s (Error: %d)"), str, _tcserror(errno), errno);
+ mir_sntprintf(error, TranslateT("List cannot be exported to file \"%s\" because of error:\n\t%s (Error: %d)"), str, _tcserror(errno), errno);
MessageBox(NULL, error, m_tszUserName, MB_OK | MB_ICONSTOP);
debugLogA("export_text(): Cannot export list to file \"%s\". errno=%d: %s", str, errno, strerror(errno));
}
@@ -494,7 +494,7 @@ INT_PTR GGPROTO::export_server(WPARAM wParam, LPARAM lParam)
{
TCHAR error[128];
gg_LeaveCriticalSection(&sess_mutex, "export_server", 67, 1, "sess_mutex", 1);
- mir_sntprintf(error, SIZEOF(error), TranslateT("List cannot be exported because of error:\n\t%s (Error: %d)"), _tcserror(errno), errno);
+ mir_sntprintf(error, TranslateT("List cannot be exported because of error:\n\t%s (Error: %d)"), _tcserror(errno), errno);
MessageBox(NULL, error, m_tszUserName, MB_OK | MB_ICONSTOP);
debugLogA("export_server(): Cannot export list. errno=%d: %s", errno, strerror(errno));
}
diff --git a/protocols/Gadu-Gadu/src/ownerinfo.cpp b/protocols/Gadu-Gadu/src/ownerinfo.cpp
index 7c8da3e1a4..96707513f2 100644
--- a/protocols/Gadu-Gadu/src/ownerinfo.cpp
+++ b/protocols/Gadu-Gadu/src/ownerinfo.cpp
@@ -57,7 +57,7 @@ void __cdecl GGPROTO::remindpasswordthread(void *param)
if (!(h = gg_remind_passwd3(rp->uin, rp->email, token.id, token.val, 0)))
{
TCHAR error[128];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Password could not be reminded because of error:\n\t%s (Error: %d)"), _tcserror(errno), errno);
+ mir_sntprintf(error, TranslateT("Password could not be reminded because of error:\n\t%s (Error: %d)"), _tcserror(errno), errno);
MessageBox(NULL, error, m_tszUserName, MB_OK | MB_ICONSTOP);
debugLogA("remindpasswordthread(): Password could not be reminded. errno=%d: %s", errno, strerror(errno));
}
diff --git a/protocols/Gadu-Gadu/src/services.cpp b/protocols/Gadu-Gadu/src/services.cpp
index e9c5b1adc6..834ccc8876 100644
--- a/protocols/Gadu-Gadu/src/services.cpp
+++ b/protocols/Gadu-Gadu/src/services.cpp
@@ -240,7 +240,7 @@ INT_PTR GGPROTO::getavatarinfo(WPARAM wParam, LPARAM lParam)
if (_tremove(pai->filename) != 0){
debugLog(_T("getavatarinfo(): refresh. _tremove 1 file %s error. errno=%d: %s"), pai->filename, errno, strerror(errno));
TCHAR error[512];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Cannot remove old avatar file before refresh. ERROR: %d: %s\n%s"), errno, _tcserror(errno), pai->filename);
+ mir_sntprintf(error, TranslateT("Cannot remove old avatar file before refresh. ERROR: %d: %s\n%s"), errno, _tcserror(errno), pai->filename);
showpopup(m_tszUserName, error, GG_POPUP_ERROR);
}
setString(pai->hContact, GG_KEY_AVATARHASH, AvatarHash);
@@ -255,7 +255,7 @@ INT_PTR GGPROTO::getavatarinfo(WPARAM wParam, LPARAM lParam)
if (_tremove(pai->filename) != 0){
debugLog(_T("getavatarinfo(): delete. _tremove file %s error. errno=%d: %s"), pai->filename, errno, strerror(errno));
TCHAR error[512];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Cannot remove old avatar file. ERROR: %d: %s\n%s"), errno, _tcserror(errno), pai->filename);
+ mir_sntprintf(error, TranslateT("Cannot remove old avatar file. ERROR: %d: %s\n%s"), errno, _tcserror(errno), pai->filename);
showpopup(m_tszUserName, error, GG_POPUP_ERROR);
}
delSetting(pai->hContact, GG_KEY_AVATARHASH);
diff --git a/protocols/Gadu-Gadu/src/sessions.cpp b/protocols/Gadu-Gadu/src/sessions.cpp
index b1625f4471..07ee15a443 100644
--- a/protocols/Gadu-Gadu/src/sessions.cpp
+++ b/protocols/Gadu-Gadu/src/sessions.cpp
@@ -330,7 +330,7 @@ static INT_PTR CALLBACK gg_sessions_viewdlg(HWND hwndDlg, UINT message, WPARAM w
ListView_GetItemText(hList, lvhti.iItem, 0, szClientName, SIZEOF(szClientName));
ListView_GetItemText(hList, lvhti.iItem, 1, szIP, SIZEOF(szIP));
ListView_GetItemText(hList, lvhti.iItem, 2, szLoginTime, SIZEOF(szLoginTime));
- mir_sntprintf(szText, SIZEOF(szText), _T("%s\t%s\t%s"), szClientName, szIP, szLoginTime);
+ mir_sntprintf(szText, _T("%s\t%s\t%s"), szClientName, szIP, szLoginTime);
if ((hData = GlobalAlloc(GMEM_MOVEABLE, mir_tstrlen(szText) + 1)) != NULL)
{
mir_tstrcpy((TCHAR*)GlobalLock(hData), szText);
diff --git a/protocols/Gadu-Gadu/src/token.cpp b/protocols/Gadu-Gadu/src/token.cpp
index 2fcf36d31d..11f72ef8ce 100644
--- a/protocols/Gadu-Gadu/src/token.cpp
+++ b/protocols/Gadu-Gadu/src/token.cpp
@@ -117,7 +117,7 @@ int GGPROTO::gettoken(GGTOKEN *token)
if (!(h = gg_token(0)) || gg_token_watch_fd(h) || h->state == GG_STATE_ERROR || h->state != GG_STATE_DONE) {
TCHAR error[128];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Token retrieval failed because of error:\n\t%s"), http_error_string(h ? h->error : 0));
+ mir_sntprintf(error, TranslateT("Token retrieval failed because of error:\n\t%s"), http_error_string(h ? h->error : 0));
MessageBox(NULL, error, m_tszUserName, MB_OK | MB_ICONSTOP);
gg_free_pubdir(h);
return FALSE;
@@ -125,7 +125,7 @@ int GGPROTO::gettoken(GGTOKEN *token)
if (!(t = (struct gg_token *)h->data) || (!h->body)) {
TCHAR error[128];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Token retrieval failed because of error:\n\t%s"), http_error_string(h ? h->error : 0));
+ mir_sntprintf(error, TranslateT("Token retrieval failed because of error:\n\t%s"), http_error_string(h ? h->error : 0));
MessageBox(NULL, error, m_tszUserName, MB_OK | MB_ICONSTOP);
gg_free_pubdir(h);
return FALSE;
diff --git a/protocols/Gadu-Gadu/src/userutils.cpp b/protocols/Gadu-Gadu/src/userutils.cpp
index a5fcae5ee3..ec4441b2a3 100644
--- a/protocols/Gadu-Gadu/src/userutils.cpp
+++ b/protocols/Gadu-Gadu/src/userutils.cpp
@@ -40,7 +40,7 @@ void *gg_doregister(GGPROTO *gg, char *newPass, char *newEmail)
if (!(h = gg_register3(newEmail, newPass, token.id, token.val, 0)) || !(s = (gg_pubdir*)h->data) || !s->success || !s->uin) {
TCHAR error[128];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Cannot register new account because of error:\n\t%s"),
+ mir_sntprintf(error, TranslateT("Cannot register new account because of error:\n\t%s"),
(h && !s) ? http_error_string(h ? h->error : 0) :
(s ? TranslateT("Registration rejected") : _tcserror(errno)));
MessageBox(NULL, error, gg->m_tszUserName, MB_OK | MB_ICONSTOP);
@@ -85,7 +85,7 @@ void *gg_dounregister(GGPROTO *gg, uin_t uin, char *password)
if (!(h = gg_unregister3(uin, password, token.id, token.val, 0)) || !(s = (gg_pubdir*)h->data) || !s->success || s->uin != uin)
{
TCHAR error[128];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Your account cannot be removed because of error:\n\t%s"),
+ mir_sntprintf(error, TranslateT("Your account cannot be removed because of error:\n\t%s"),
(h && !s) ? http_error_string(h ? h->error : 0) :
(s ? TranslateT("Bad number or password") : _tcserror(errno)));
MessageBox(NULL, error, gg->m_tszUserName, MB_OK | MB_ICONSTOP);
@@ -137,7 +137,7 @@ void *gg_dochpass(GGPROTO *gg, uin_t uin, char *password, char *newPass)
if (!(h = gg_change_passwd4(uin, email, password, newPass, token.id, token.val, 0)) || !(s = (gg_pubdir*)h->data) || !s->success)
{
TCHAR error[128];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Your password cannot be changed because of error:\n\t%s"),
+ mir_sntprintf(error, TranslateT("Your password cannot be changed because of error:\n\t%s"),
(h && !s) ? http_error_string(h ? h->error : 0) :
(s ? TranslateT("Invalid data entered") : _tcserror(errno)));
MessageBox(NULL, error, gg->m_tszUserName, MB_OK | MB_ICONSTOP);
@@ -179,7 +179,7 @@ void *gg_dochemail(GGPROTO *gg, uin_t uin, char *password, char *email, char *ne
if (!(h = gg_change_passwd4(uin, newEmail, password, password, token.id, token.val, 0)) || !(s = (gg_pubdir*)h->data) || !s->success)
{
TCHAR error[128];
- mir_sntprintf(error, SIZEOF(error), TranslateT("Your e-mail cannot be changed because of error:\n\t%s"),
+ mir_sntprintf(error, TranslateT("Your e-mail cannot be changed because of error:\n\t%s"),
(h && !s) ? http_error_string(h ? h->error : 0) : (s ? TranslateT("Bad old e-mail or password") : _tcserror(errno)));
MessageBox(NULL, error, gg->m_tszUserName, MB_OK | MB_ICONSTOP);
gg->debugLogA("gg_dochemail(): Cannot change e-mail. errno=%d: %s", errno, strerror(errno));