diff options
Diffstat (limited to 'plugins/FTPFileYM/src')
| -rw-r--r-- | plugins/FTPFileYM/src/mir_db.cpp | 22 | ||||
| -rw-r--r-- | plugins/FTPFileYM/src/mir_db.h | 3 | ||||
| -rw-r--r-- | plugins/FTPFileYM/src/serverlist.cpp | 8 | 
3 files changed, 2 insertions, 31 deletions
diff --git a/plugins/FTPFileYM/src/mir_db.cpp b/plugins/FTPFileYM/src/mir_db.cpp index 63e85cc056..13d1d645a7 100644 --- a/plugins/FTPFileYM/src/mir_db.cpp +++ b/plugins/FTPFileYM/src/mir_db.cpp @@ -53,14 +53,6 @@ int DB::setStringF(HANDLE hContact, char *szModule, char *szSetting, int id, TCH  	return db_set_ts(hContact, szModule, formSet, stzValue);
  }
 -int DB::setCryptedString(HANDLE hContact, char *szModule, char *szSetting, char *szValue)
 -{
 -	char buff[256];
 -	strcpy(buff, szValue);
 -	CallService(MS_DB_CRYPT_ENCODESTRING, (WPARAM)sizeof(buff), (LPARAM)buff);
 -	return db_set_s(hContact, szModule, szSetting, buff);
 -}
 -
  int DB::getByteF(HANDLE hContact, char *szModule, char *szSetting, int id, int iErrorValue)
  {
  	char formSet[256];
 @@ -124,20 +116,6 @@ int DB::getStringF(HANDLE hContact, char *szModule, char *szSetting, int id, TCH  	return getString(hContact, szModule, formSet, buff);
  }
 -int DB::getCryptedString(HANDLE hContact, char *szModule, char *szSetting, char *szValue)
 -{
 -	char buff[256];
 -	if (!getAString(hContact, szModule, szSetting, buff))
 -	{
 -		CallService(MS_DB_CRYPT_DECODESTRING, (WPARAM)sizeof(buff), (LPARAM)buff);
 -		strcpy(szValue, buff);
 -		return 0;
 -	}
 -
 -	szValue[0] = 0;
 -	return 1;
 -}
 -
  int DB::deleteSettingF(HANDLE hContact, char *szModule, char *szSetting, int id)
  {
  	char formSet[256];
 diff --git a/plugins/FTPFileYM/src/mir_db.h b/plugins/FTPFileYM/src/mir_db.h index 84f81b82bb..d46b16fb06 100644 --- a/plugins/FTPFileYM/src/mir_db.h +++ b/plugins/FTPFileYM/src/mir_db.h @@ -40,8 +40,5 @@ public:  	static int getString(HANDLE hContact, char *szModule, char *szSetting, TCHAR *buff);
  	static int getStringF(HANDLE hContact, char *szModule, char *szSetting, int id, TCHAR *buff);
 -	static int setCryptedString(HANDLE hContact, char *szModule, char *szSetting, char *szValue);
 -	static int getCryptedString(HANDLE hContact, char *szModule, char *szSetting, char *szValue);
 -
  	static int deleteSettingF(HANDLE hContact, char *szModule, char *szSetting, int id);
  };
 diff --git a/plugins/FTPFileYM/src/serverlist.cpp b/plugins/FTPFileYM/src/serverlist.cpp index 79aea87d29..d199228675 100644 --- a/plugins/FTPFileYM/src/serverlist.cpp +++ b/plugins/FTPFileYM/src/serverlist.cpp @@ -46,7 +46,7 @@ void ServerList::saveToDb() const  	char buff[256];
  	mir_snprintf(buff, sizeof(buff), "Password%d", opt.selected);
 -	DB::setCryptedString(0, MODULE, buff, ftp->szPass);
 +	DB::setAStringF(0, MODULE, buff, opt.selected, ftp->szPass);
  	DB::setStringF(0, MODULE, "Name%d", opt.selected, ftp->stzName);
  	DB::setAStringF(0, MODULE, "Server%d", opt.selected, ftp->szServer);
 @@ -64,14 +64,10 @@ void ServerList::saveToDb() const  ServerList::FTP::FTP(int index)
  {
 -	char buff[256];
 -
  	if (DB::getStringF(0, MODULE, "Name%d", index, this->stzName))
  		mir_sntprintf(this->stzName, SIZEOF(this->stzName), TranslateT("FTP Server %d"), index + 1);
 -	mir_snprintf(buff, sizeof(buff), "Password%d", index);
 -	DB::getCryptedString(0, MODULE, buff, this->szPass);
 -
 +	DB::getAStringF(0, MODULE, "Password%d", index, this->szPass);
  	DB::getAStringF(0, MODULE, "Server%d", index, this->szServer);
  	DB::getAStringF(0, MODULE, "User%d", index, this->szUser);
  	DB::getAStringF(0, MODULE, "Url%d", index, this->szUrl);
  | 
