From 9b119cadd74e1343cad493e8b366e69743a620d0 Mon Sep 17 00:00:00 2001 From: Kirill Volinsky Date: Sun, 21 Dec 2014 09:49:05 +0000 Subject: Quotes: changed warning level to w4 git-svn-id: http://svn.miranda-ng.org/main/trunk@11552 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/Quotes/src/DBUtils.cpp | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'plugins/Quotes/src/DBUtils.cpp') diff --git a/plugins/Quotes/src/DBUtils.cpp b/plugins/Quotes/src/DBUtils.cpp index 1636419ac9..e2d9f5f15e 100644 --- a/plugins/Quotes/src/DBUtils.cpp +++ b/plugins/Quotes/src/DBUtils.cpp @@ -1,15 +1,15 @@ #include "StdAfx.h" -std::string Quotes_DBGetStringA(MCONTACT hContact,const char* szModule,const char* szSetting,const char* pszDefValue /*= NULL*/) +std::string Quotes_DBGetStringA(MCONTACT hContact, const char* szModule, const char* szSetting, const char* pszDefValue /*= NULL*/) { std::string sResult; - char* pszSymbol = db_get_sa(hContact,szModule,szSetting); - if(NULL != pszSymbol) + char* pszSymbol = db_get_sa(hContact, szModule, szSetting); + if (NULL != pszSymbol) { sResult = pszSymbol; mir_free(pszSymbol); } - else if(NULL != pszDefValue) + else if (NULL != pszDefValue) { sResult = pszDefValue; } @@ -17,16 +17,16 @@ std::string Quotes_DBGetStringA(MCONTACT hContact,const char* szModule,const cha return sResult; } -std::wstring Quotes_DBGetStringW(MCONTACT hContact,const char* szModule,const char* szSetting,const wchar_t* pszDefValue/* = NULL*/) +std::wstring Quotes_DBGetStringW(MCONTACT hContact, const char* szModule, const char* szSetting, const wchar_t* pszDefValue/* = NULL*/) { std::wstring sResult; - wchar_t* pszSymbol = db_get_wsa(hContact,szModule,szSetting); - if(NULL != pszSymbol) + wchar_t* pszSymbol = db_get_wsa(hContact, szModule, szSetting); + if (NULL != pszSymbol) { sResult = pszSymbol; mir_free(pszSymbol); } - else if(NULL != pszDefValue) + else if (NULL != pszDefValue) { sResult = pszDefValue; } @@ -34,18 +34,18 @@ std::wstring Quotes_DBGetStringW(MCONTACT hContact,const char* szModule,const ch return sResult; } -bool Quotes_DBWriteDouble(MCONTACT hContact,const char* szModule,const char* szSetting,double dValue) +bool Quotes_DBWriteDouble(MCONTACT hContact, const char* szModule, const char* szSetting, double dValue) { return 0 == db_set_blob(hContact, szModule, szSetting, &dValue, sizeof(dValue)); } -bool Quotes_DBReadDouble(MCONTACT hContact,const char* szModule,const char* szSetting,double& rdValue) +bool Quotes_DBReadDouble(MCONTACT hContact, const char* szModule, const char* szSetting, double& rdValue) { - DBVARIANT dbv = {0}; + DBVARIANT dbv = { 0 }; dbv.type = DBVT_BLOB; bool bResult = ((0 == db_get(hContact, szModule, szSetting, &dbv)) && (DBVT_BLOB == dbv.type)); - if(bResult) + if (bResult) rdValue = *reinterpret_cast(dbv.pbVal); db_free(&dbv); -- cgit v1.2.3