From aa090255cfc30e3aeef7e2ed8d1c8eac3e477cdb Mon Sep 17 00:00:00 2001 From: George Hazan Date: Thu, 14 Mar 2013 14:31:39 +0000 Subject: fix: various problems with memory git-svn-id: http://svn.miranda-ng.org/main/trunk@4025 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/AVS/src/acc.h | 14 -------------- plugins/AVS/src/main.cpp | 4 ++-- 2 files changed, 2 insertions(+), 16 deletions(-) (limited to 'plugins/AVS/src') diff --git a/plugins/AVS/src/acc.h b/plugins/AVS/src/acc.h index 11b235adc0..79f0d826a1 100644 --- a/plugins/AVS/src/acc.h +++ b/plugins/AVS/src/acc.h @@ -21,20 +21,6 @@ Boston, MA 02111-1307, USA. #ifndef __ACC_H__ # define __ACC_H__ -class A2T -{ - TCHAR* buf; - -public: - A2T( const char* s ) : buf( mir_a2t( s )) {} - A2T( const char* s, int cp ) : buf( mir_a2t_cp( s, cp )) {} - ~A2T() { mir_free(buf); } - - __forceinline operator TCHAR*() const - { return buf; - } -}; - INT_PTR avSetAvatar( HANDLE hContact, TCHAR* tszPath ); INT_PTR avSetMyAvatar( char* szProto, TCHAR* tszPath ); diff --git a/plugins/AVS/src/main.cpp b/plugins/AVS/src/main.cpp index 2cc5b49c40..ca1f696a64 100644 --- a/plugins/AVS/src/main.cpp +++ b/plugins/AVS/src/main.cpp @@ -914,7 +914,7 @@ INT_PTR avSetAvatar(HANDLE hContact, TCHAR* tszPath) } INT_PTR SetAvatar(WPARAM wParam, LPARAM lParam) -{ return avSetAvatar(( HANDLE )wParam, A2T(( const char* )lParam )); +{ return avSetAvatar(( HANDLE )wParam, _A2T(( const char* )lParam )); } INT_PTR SetAvatarW(WPARAM wParam, LPARAM lParam) @@ -1461,7 +1461,7 @@ INT_PTR avSetMyAvatar( char* protocol, TCHAR* tszPath ) } static INT_PTR SetMyAvatar( WPARAM wParam, LPARAM lParam ) -{ return avSetMyAvatar(( char* )wParam, A2T(( const char* )lParam )); +{ return avSetMyAvatar(( char* )wParam, _A2T(( const char* )lParam )); } static INT_PTR SetMyAvatarW( WPARAM wParam, LPARAM lParam ) -- cgit v1.2.3