diff options
Diffstat (limited to 'protocols/Gadu-Gadu/src')
-rw-r--r-- | protocols/Gadu-Gadu/src/avatar.cpp | 10 | ||||
-rw-r--r-- | protocols/Gadu-Gadu/src/gg.cpp | 8 | ||||
-rw-r--r-- | protocols/Gadu-Gadu/src/gg_proto.cpp | 3 | ||||
-rw-r--r-- | protocols/Gadu-Gadu/src/gg_proto.h | 1 |
4 files changed, 3 insertions, 19 deletions
diff --git a/protocols/Gadu-Gadu/src/avatar.cpp b/protocols/Gadu-Gadu/src/avatar.cpp index 33418c0fcd..c3e2448567 100644 --- a/protocols/Gadu-Gadu/src/avatar.cpp +++ b/protocols/Gadu-Gadu/src/avatar.cpp @@ -28,15 +28,7 @@ void GGPROTO::getAvatarFilename(HANDLE hContact, TCHAR *pszDest, int cbLen)
{
- int tPathLen;
- TCHAR *path = (TCHAR*)alloca(cbLen * sizeof(TCHAR));
-
- if (hAvatarsFolder == NULL || FoldersGetCustomPathT(hAvatarsFolder, path, cbLen, _T("")))
- tPathLen = mir_sntprintf(pszDest, cbLen, _T("%s\\%S"), VARST( _T("%miranda_avatarcache%")), m_szModuleName);
- else {
- _tcscpy(pszDest, path);
- tPathLen = (int)_tcslen(pszDest);
- }
+ int tPathLen = mir_sntprintf(pszDest, cbLen, _T("%s\\%S"), VARST( _T("%miranda_avatarcache%")), m_szModuleName);
if (_taccess(pszDest, 0)) {
int ret = CreateDirectoryTreeT(pszDest);
diff --git a/protocols/Gadu-Gadu/src/gg.cpp b/protocols/Gadu-Gadu/src/gg.cpp index e10057af73..932d3410a1 100644 --- a/protocols/Gadu-Gadu/src/gg.cpp +++ b/protocols/Gadu-Gadu/src/gg.cpp @@ -147,20 +147,16 @@ extern "C" __declspec(dllexport) const MUUID MirandaInterfaces[] = {MIID_PROTOCO void GGPROTO::cleanuplastplugin(DWORD version)
{
-
// Store current plugin version
setDword(GG_PLUGINVERSION, pluginInfo.version);
-
//1. clean files: %miranda_avatarcache%\GG\*.(null)
if (version < PLUGIN_MAKE_VERSION(0, 11, 0, 2)){
netlog("cleanuplastplugin() 1: version=%d Cleaning junk avatar files from < 0.11.0.2", version);
TCHAR avatarsPath[MAX_PATH];
- if (hAvatarsFolder == NULL || FoldersGetCustomPathT(hAvatarsFolder, avatarsPath, MAX_PATH, _T(""))) {
- ptrT tmpPath( Utils_ReplaceVarsT( _T("%miranda_avatarcache%")));
- mir_sntprintf(avatarsPath, MAX_PATH, _T("%s\\%s"), (TCHAR*)tmpPath, m_tszUserName);
- }
+ mir_sntprintf(avatarsPath, MAX_PATH, _T("%s\\%s"), VARST( _T("%miranda_avatarcache%")), m_tszUserName);
+
netlog("cleanuplastplugin() 1: miranda_avatarcache = %S", avatarsPath);
if (avatarsPath != NULL){
diff --git a/protocols/Gadu-Gadu/src/gg_proto.cpp b/protocols/Gadu-Gadu/src/gg_proto.cpp index 991b30ee5f..d8dabc0b56 100644 --- a/protocols/Gadu-Gadu/src/gg_proto.cpp +++ b/protocols/Gadu-Gadu/src/gg_proto.cpp @@ -69,9 +69,6 @@ GGPROTO::GGPROTO(const char* pszProtoName, const TCHAR* tszUserName) : db_set_resident(m_szModuleName, GG_KEY_AVATARREQUESTED);
TCHAR szPath[MAX_PATH];
- mir_sntprintf(szPath, MAX_PATH, _T("%s\\%s"), (TCHAR*)VARST( _T("%miranda_avatarcache%")), m_tszUserName);
- hAvatarsFolder = FoldersRegisterCustomPathT(LPGEN("Avatars"), m_szModuleName, szPath, m_tszUserName);
-
mir_sntprintf(szPath, MAX_PATH, _T("%s\\%s\\ImageCache"), (TCHAR*)VARST( _T("%miranda_userdata%")), m_tszUserName);
hImagesFolder = FoldersRegisterCustomPathT(LPGEN("Images"), m_szModuleName, szPath, m_tszUserName);
diff --git a/protocols/Gadu-Gadu/src/gg_proto.h b/protocols/Gadu-Gadu/src/gg_proto.h index f10435168d..1f91546bce 100644 --- a/protocols/Gadu-Gadu/src/gg_proto.h +++ b/protocols/Gadu-Gadu/src/gg_proto.h @@ -267,7 +267,6 @@ struct GGPROTO : public PROTO<GGPROTO> HGENMENU hMainMenu[7];
HGENMENU hBlockMenuItem, hImageMenuItem, hInstanceMenuItem;
HANDLE hPrebuildMenuHook;
- HANDLE hAvatarsFolder;
HANDLE hImagesFolder;
HWND hwndSessionsDlg;
HANDLE hPopupNotify, hPopupError;
|