diff options
author | George Hazan <ghazan@miranda.im> | 2018-05-03 16:02:14 +0200 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-05-03 16:02:14 +0200 |
commit | 3ad2582c4a4a6378f294f9256ecbcbdf0ae88e3a (patch) | |
tree | 412a28ef6a572efc7039df1c363bf47a3dec4b19 /plugins/CloudFile | |
parent | 9a6f750a482d1d1ebf4281bb7bf8133e547ad438 (diff) |
mir_forkThread<typename> - stronger typizatioin for thread function parameter
Diffstat (limited to 'plugins/CloudFile')
-rw-r--r-- | plugins/CloudFile/src/Services/google_service.cpp | 6 | ||||
-rw-r--r-- | plugins/CloudFile/src/Services/microsoft_service.cpp | 6 | ||||
-rw-r--r-- | plugins/CloudFile/src/Services/yandex_service.cpp | 6 | ||||
-rw-r--r-- | plugins/CloudFile/src/utils.cpp | 2 |
4 files changed, 10 insertions, 10 deletions
diff --git a/plugins/CloudFile/src/Services/google_service.cpp b/plugins/CloudFile/src/Services/google_service.cpp index cd1d252c11..798981a9c9 100644 --- a/plugins/CloudFile/src/Services/google_service.cpp +++ b/plugins/CloudFile/src/Services/google_service.cpp @@ -36,7 +36,7 @@ bool CGDriveService::IsLoggedIn() ptrA token(getStringA("TokenSecret")); if (!token || token[0] == 0) return false; - time_t now = time(nullptr); + time_t now = time(0); time_t expiresIn = getDword("ExpiresIn"); return now < expiresIn; } @@ -55,7 +55,7 @@ void CGDriveService::Login(HWND owner) setString("TokenSecret", node.as_string().c_str()); node = root.at("expires_in"); - time_t expiresIn = time(nullptr) + node.as_int(); + time_t expiresIn = time(0) + node.as_int(); setDword("ExpiresIn", expiresIn); return; @@ -116,7 +116,7 @@ void CGDriveService::RequestAccessTokenThread(void *param) db_set_s(NULL, GetAccountName(), "TokenSecret", node.as_string().c_str()); node = root.at("expires_in"); - time_t expiresIn = time(nullptr) + node.as_int(); + time_t expiresIn = time(0) + node.as_int(); db_set_dw(NULL, GetAccountName(), "ExpiresIn", expiresIn); node = root.at("refresh_token"); diff --git a/plugins/CloudFile/src/Services/microsoft_service.cpp b/plugins/CloudFile/src/Services/microsoft_service.cpp index 2a3f3c19b4..722560aec8 100644 --- a/plugins/CloudFile/src/Services/microsoft_service.cpp +++ b/plugins/CloudFile/src/Services/microsoft_service.cpp @@ -36,7 +36,7 @@ bool COneDriveService::IsLoggedIn() ptrA token(getStringA("TokenSecret")); if (!token || token[0] == 0) return false; - time_t now = time(nullptr); + time_t now = time(0); time_t expiresIn = getDword("ExpiresIn"); return now < expiresIn; } @@ -54,7 +54,7 @@ void COneDriveService::Login(HWND owner) db_set_s(NULL, GetAccountName(), "TokenSecret", node.as_string().c_str()); node = root.at("expires_in"); - time_t expiresIn = time(nullptr) + node.as_int(); + time_t expiresIn = time(0) + node.as_int(); setDword("ExpiresIn", expiresIn); return; @@ -117,7 +117,7 @@ void COneDriveService::RequestAccessTokenThread(void *param) setString("TokenSecret", node.as_string().c_str()); node = root.at("expires_in"); - time_t expiresIn = time(nullptr) + node.as_int(); + time_t expiresIn = time(0) + node.as_int(); setDword("ExpiresIn", expiresIn); node = root.at("refresh_token"); diff --git a/plugins/CloudFile/src/Services/yandex_service.cpp b/plugins/CloudFile/src/Services/yandex_service.cpp index acc9fb0315..6609e7c4b3 100644 --- a/plugins/CloudFile/src/Services/yandex_service.cpp +++ b/plugins/CloudFile/src/Services/yandex_service.cpp @@ -36,7 +36,7 @@ bool CYandexService::IsLoggedIn() ptrA token(getStringA("TokenSecret")); if (!token || token[0] == 0) return false; - time_t now = time(nullptr); + time_t now = time(0); time_t expiresIn = getDword("ExpiresIn"); return now < expiresIn; } @@ -55,7 +55,7 @@ void CYandexService::Login(HWND owner) setString("TokenSecret", node.as_string().c_str()); node = root.at("expires_in"); - time_t expiresIn = time(nullptr) + node.as_int(); + time_t expiresIn = time(0) + node.as_int(); setDword("ExpiresIn", expiresIn); node = root.at("refresh_token"); @@ -119,7 +119,7 @@ void CYandexService::RequestAccessTokenThread(void *param) setString("TokenSecret", node.as_string().c_str()); node = root.at("expires_in"); - time_t expiresIn = time(nullptr) + node.as_int(); + time_t expiresIn = time(0) + node.as_int(); setDword("ExpiresIn", expiresIn); node = root.at("refresh_token"); diff --git a/plugins/CloudFile/src/utils.cpp b/plugins/CloudFile/src/utils.cpp index 4d1ed11fa6..cb9bb8bf94 100644 --- a/plugins/CloudFile/src/utils.cpp +++ b/plugins/CloudFile/src/utils.cpp @@ -28,7 +28,7 @@ MEVENT AddEventToDb(MCONTACT hContact, WORD type, DWORD flags, DWORD cbBlob, PBY { DBEVENTINFO dbei = {}; dbei.szModule = MODULE; - dbei.timestamp = time(nullptr); + dbei.timestamp = time(0); dbei.eventType = type; dbei.cbBlob = cbBlob; dbei.pBlob = pBlob; |