From d6eee2018898f2442883a0aa77ad095b75572cfb Mon Sep 17 00:00:00 2001 From: George Hazan Date: Thu, 27 Aug 2015 15:15:33 +0000 Subject: fix for 64-bit issues & warnings git-svn-id: http://svn.miranda-ng.org/main/trunk@15043 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/WebView/src/webview_alerts.cpp | 10 +++++----- plugins/WebView/src/webview_services.cpp | 10 +++++----- 2 files changed, 10 insertions(+), 10 deletions(-) (limited to 'plugins/WebView/src') diff --git a/plugins/WebView/src/webview_alerts.cpp b/plugins/WebView/src/webview_alerts.cpp index 20f5e3476a..b790468edb 100644 --- a/plugins/WebView/src/webview_alerts.cpp +++ b/plugins/WebView/src/webview_alerts.cpp @@ -432,7 +432,7 @@ int ProcessAlerts(MCONTACT hContact, char *truncated, char *tstr, char *contactn // file exists? if ( _taccess(newcachepath, 0) != -1) { if ((pcachefile = _tfopen(newcachepath, _T("r"))) == NULL) - WErrorPopup((MCONTACT)contactname, TranslateT("Cannot read from file")); + WErrorPopup((UINT_PTR)contactname, TranslateT("Cannot read from file")); else { memset(&cachecompare, 0, sizeof(cachecompare)); fread(cachecompare, sizeof(cachecompare), 1, pcachefile); @@ -441,7 +441,7 @@ int ProcessAlerts(MCONTACT hContact, char *truncated, char *tstr, char *contactn } // write to cache if ((pcachefile = _tfopen(newcachepath, _T("w"))) == NULL) - WErrorPopup((MCONTACT)contactname, TranslateT("Cannot write to file 1")); + WErrorPopup((UINT_PTR)contactname, TranslateT("Cannot write to file 1")); else { fwrite(tempraw, mir_strlen(tempraw), 1, pcachefile); //smaller cache fclose(pcachefile); @@ -644,7 +644,7 @@ int ProcessAlerts(MCONTACT hContact, char *truncated, char *tstr, char *contactn // file exists? if ( _taccess(newcachepath, 0) != -1) { if ((pcachefile = _tfopen(newcachepath, _T("r"))) == NULL) - WErrorPopup((MCONTACT)contactname, TranslateT("Cannot read from file")); + WErrorPopup((UINT_PTR)contactname, TranslateT("Cannot read from file")); else { memset(&cachecompare, 0, sizeof(cachecompare)); fread(cachecompare, sizeof(cachecompare), 1, pcachefile); @@ -653,7 +653,7 @@ int ProcessAlerts(MCONTACT hContact, char *truncated, char *tstr, char *contactn } // write to cache if ((pcachefile = _tfopen(newcachepath, _T("w"))) == NULL) - WErrorPopup((MCONTACT)contactname, TranslateT("Cannot write to file 2")); + WErrorPopup((UINT_PTR)contactname, TranslateT("Cannot write to file 2")); else { fwrite(raw, mir_strlen(raw), 1, pcachefile); //smaller cache db_set_ts(hContact, MODULENAME, CACHE_FILE_KEY, newcachepath); @@ -791,7 +791,7 @@ int DataWndAlertCommand(WPARAM wParam, LPARAM) /*****************************************************************************/ void ReadFromFile(void *param) { - MCONTACT hContact = (MCONTACT)param; + MCONTACT hContact = (UINT_PTR)param; DBVARIANT dbv; char truncated[MAXSIZE1]; diff --git a/plugins/WebView/src/webview_services.cpp b/plugins/WebView/src/webview_services.cpp index d47a621713..80472ae058 100644 --- a/plugins/WebView/src/webview_services.cpp +++ b/plugins/WebView/src/webview_services.cpp @@ -60,7 +60,7 @@ int DBSettingChanged(WPARAM wParam, LPARAM lParam) for (int i=0; i < _countof(szInvalidChars); i++ ) { TCHAR *p = _tcschr(nick, szInvalidChars[i]); if (p != NULL) { - WErrorPopup((MCONTACT)"ERROR", TranslateT("Invalid symbol present in contact name.")); + WErrorPopup((UINT_PTR)"ERROR", TranslateT("Invalid symbol present in contact name.")); *p = '_'; invalidpresent =1; } @@ -149,10 +149,10 @@ INT_PTR OpenCacheDir(WPARAM, LPARAM) cacheend++; *cacheend = '\0'; - mir_sntprintf(cachedirectorypath, _countof(cachedirectorypath), _T("%s")_T(MODULENAME)_T("cache\\%s"), cachepath, cacheend); + mir_sntprintf(cachedirectorypath, _T("%s")_T(MODULENAME)_T("cache\\%s"), cachepath, cacheend); if( _taccess(cachedirectorypath, 0) != 0) - WErrorPopup((MCONTACT)"ERROR", TranslateT("Cache folder does not exist.")); + WErrorPopup((UINT_PTR)"ERROR", TranslateT("Cache folder does not exist.")); else ShellExecute(NULL, _T("open"), cachedirectorypath, NULL, NULL, SW_SHOWNORMAL); return 0; @@ -163,7 +163,7 @@ INT_PTR PingWebsiteMenuCommand(WPARAM wParam, LPARAM) { FILE *pfile = fopen("psite.bat", "r"); if (pfile == NULL) { - WErrorPopup((MCONTACT)"ERROR", TranslateT("Missing \"psite.bat\" file.")); + WErrorPopup((UINT_PTR)"ERROR", TranslateT("Missing \"psite.bat\" file.")); return 0; } @@ -344,7 +344,7 @@ INT_PTR AddToList(WPARAM, LPARAM lParam) if (psr == NULL) return 0; if (psr->nick.t == NULL) { - WErrorPopup((MCONTACT)"ERROR", TranslateT("Please select site in Find/Add contacts...")); + WErrorPopup((UINT_PTR)"ERROR", TranslateT("Please select site in Find/Add contacts...")); return 0; } // if contact with the same ID was not found, add it -- cgit v1.2.3