From: Maxim Mamontov Date: Sat, 13 Aug 2011 16:06:55 +0000 (+0300) Subject: Fix compilation errors got after API changes X-Git-Tag: 2.408-alpha~33 X-Git-Url: https://git.stg.codes/stg.git/commitdiff_plain/02be813c72c75c61beaef0266bd5adf713e67b42 Fix compilation errors got after API changes --- diff --git a/projects/stargazer/plugins/configuration/rpcconfig/admins_methods.cpp b/projects/stargazer/plugins/configuration/rpcconfig/admins_methods.cpp index 2dbc9a7d..3607a806 100644 --- a/projects/stargazer/plugins/configuration/rpcconfig/admins_methods.cpp +++ b/projects/stargazer/plugins/configuration/rpcconfig/admins_methods.cpp @@ -23,7 +23,7 @@ if (config->GetAdminInfo(cookie, &adminInfo)) ADMIN * admin; -if (admins->FindAdmin(login, &admin)) +if (admins->Find(login, &admin)) { structVal["result"] = xmlrpc_c::value_boolean(false); *retvalPtr = xmlrpc_c::value_struct(structVal); @@ -67,7 +67,7 @@ if (config->GetAdminInfo(cookie, &adminInfo)) ADMIN * admin; -if (admins->FindAdmin(adminInfo.admin, &admin)) +if (admins->Find(adminInfo.admin, &admin)) { printfd(__FILE__, "METHOD_ADMIN_ADD::execute(): 'Invalid admin (logged)'\n"); *retvalPtr = xmlrpc_c::value_boolean(false); @@ -104,7 +104,7 @@ if (config->GetAdminInfo(cookie, &adminInfo)) ADMIN * admin; -if (admins->FindAdmin(adminInfo.admin, &admin)) +if (admins->Find(adminInfo.admin, &admin)) { *retvalPtr = xmlrpc_c::value_boolean(false); return; @@ -139,7 +139,7 @@ if (config->GetAdminInfo(cookie, &adminInfo)) ADMIN * loggedAdmin; -if (admins->FindAdmin(adminInfo.admin, &loggedAdmin)) +if (admins->Find(adminInfo.admin, &loggedAdmin)) { *retvalPtr = xmlrpc_c::value_boolean(false); return; @@ -147,7 +147,7 @@ if (admins->FindAdmin(adminInfo.admin, &loggedAdmin)) ADMIN * admin; -if (admins->FindAdmin(login, &admin)) +if (admins->Find(login, &admin)) { *retvalPtr = xmlrpc_c::value_boolean(false); return; diff --git a/projects/stargazer/plugins/configuration/rpcconfig/info_methods.cpp b/projects/stargazer/plugins/configuration/rpcconfig/info_methods.cpp index 91f910e0..b971c638 100644 --- a/projects/stargazer/plugins/configuration/rpcconfig/info_methods.cpp +++ b/projects/stargazer/plugins/configuration/rpcconfig/info_methods.cpp @@ -26,9 +26,9 @@ un += " "; un += utsn.nodename; structVal["version"] = xmlrpc_c::value_string(SERVER_VERSION); -structVal["tariff_num"] = xmlrpc_c::value_int(tariffs->GetTariffsNum()); +structVal["tariff_num"] = xmlrpc_c::value_int(tariffs->Count()); structVal["tariff"] = xmlrpc_c::value_int(2); -structVal["users_num"] = xmlrpc_c::value_int(users->GetUserNum()); +structVal["users_num"] = xmlrpc_c::value_int(users->Count()); structVal["uname"] = xmlrpc_c::value_string(un); structVal["dir_num"] = xmlrpc_c::value_int(DIR_NUM); structVal["day_fee"] = xmlrpc_c::value_int(dayFee); diff --git a/projects/stargazer/plugins/configuration/rpcconfig/rpcconfig.cpp b/projects/stargazer/plugins/configuration/rpcconfig/rpcconfig.cpp index 7968e0dc..1f2b8e18 100644 --- a/projects/stargazer/plugins/configuration/rpcconfig/rpcconfig.cpp +++ b/projects/stargazer/plugins/configuration/rpcconfig/rpcconfig.cpp @@ -204,7 +204,7 @@ bool RPC_CONFIG::CheckAdmin(const std::string & login, { ADMIN * admin = NULL; -if (!admins->AdminCorrect(login, password, &admin)) +if (!admins->Correct(login, password, &admin)) { return true; } diff --git a/projects/stargazer/plugins/configuration/rpcconfig/tariffs_methods.cpp b/projects/stargazer/plugins/configuration/rpcconfig/tariffs_methods.cpp index 76142053..0b110d54 100644 --- a/projects/stargazer/plugins/configuration/rpcconfig/tariffs_methods.cpp +++ b/projects/stargazer/plugins/configuration/rpcconfig/tariffs_methods.cpp @@ -57,7 +57,7 @@ if (config->GetAdminInfo(cookie, &adminInfo)) ADMIN * admin; -if (admins->FindAdmin(adminInfo.admin, &admin)) +if (admins->Find(adminInfo.admin, &admin)) { *retvalPtr = xmlrpc_c::value_boolean(false); return; @@ -138,7 +138,7 @@ if (config->GetAdminInfo(cookie, &adminInfo)) ADMIN * admin; -if (admins->FindAdmin(adminInfo.admin, &admin)) +if (admins->Find(adminInfo.admin, &admin)) { *retvalPtr = xmlrpc_c::value_boolean(false); return; @@ -170,7 +170,7 @@ if (config->GetAdminInfo(cookie, &adminInfo)) ADMIN * admin; -if (admins->FindAdmin(adminInfo.admin, &admin)) +if (admins->Find(adminInfo.admin, &admin)) { *retvalPtr = xmlrpc_c::value_boolean(false); return; diff --git a/projects/stargazer/plugins/configuration/rpcconfig/users_methods.cpp b/projects/stargazer/plugins/configuration/rpcconfig/users_methods.cpp index fcd81a5e..4932e146 100644 --- a/projects/stargazer/plugins/configuration/rpcconfig/users_methods.cpp +++ b/projects/stargazer/plugins/configuration/rpcconfig/users_methods.cpp @@ -72,7 +72,7 @@ if (config->GetAdminInfo(cookie, &adminInfo)) ADMIN * admin = NULL; -if (admins->FindAdmin(adminInfo.admin, &admin)) +if (admins->Find(adminInfo.admin, &admin)) { *retvalPtr = xmlrpc_c::value_boolean(false); return; @@ -116,7 +116,7 @@ if (config->GetAdminInfo(cookie, &adminInfo)) ADMIN * admin; -if (admins->FindAdmin(adminInfo.admin, &admin)) +if (admins->Find(adminInfo.admin, &admin)) { *retvalPtr = xmlrpc_c::value_boolean(false); return; @@ -208,7 +208,7 @@ if (config->GetAdminInfo(cookie, &adminInfo)) ADMIN * admin; -if (admins->FindAdmin(adminInfo.admin, &admin)) +if (admins->Find(adminInfo.admin, &admin)) { *retvalPtr = xmlrpc_c::value_boolean(false); return; @@ -261,7 +261,7 @@ if (config->GetAdminInfo(cookie, &adminInfo)) ADMIN * admin; -if (admins->FindAdmin(adminInfo.admin, &admin)) +if (admins->Find(adminInfo.admin, &admin)) { *retvalPtr = xmlrpc_c::value_boolean(false); return; @@ -311,7 +311,7 @@ if (config->GetAdminInfo(cookie, &adminInfo)) ADMIN * admin; -if (admins->FindAdmin(adminInfo.admin, &admin)) +if (admins->Find(adminInfo.admin, &admin)) { *retvalPtr = xmlrpc_c::value_boolean(false); return; @@ -359,7 +359,7 @@ if (config->GetAdminInfo(cookie, &adminInfo)) ADMIN * admin; -if (admins->FindAdmin(adminInfo.admin, &admin)) +if (admins->Find(adminInfo.admin, &admin)) { *retvalPtr = xmlrpc_c::value_boolean(false); return; diff --git a/projects/stargazer/plugins/configuration/sgconfig/parser.cpp b/projects/stargazer/plugins/configuration/sgconfig/parser.cpp index 30252544..c933b5fe 100644 --- a/projects/stargazer/plugins/configuration/sgconfig/parser.cpp +++ b/projects/stargazer/plugins/configuration/sgconfig/parser.cpp @@ -63,13 +63,13 @@ answerList->push_back(""); sprintf(s, "", SERVER_VERSION); answerList->push_back(s); -sprintf(s, "", tariffs->GetTariffsNum()); +sprintf(s, "", tariffs->Count()); answerList->push_back(s); sprintf(s, "", 2); answerList->push_back(s); -sprintf(s, "", users->GetUserNum()); +sprintf(s, "", users->Count()); answerList->push_back(s); sprintf(s, "", un); diff --git a/projects/stargazer/plugins/configuration/sgconfig/rsconf.cpp b/projects/stargazer/plugins/configuration/sgconfig/rsconf.cpp index f494ee40..209ea3b2 100644 --- a/projects/stargazer/plugins/configuration/sgconfig/rsconf.cpp +++ b/projects/stargazer/plugins/configuration/sgconfig/rsconf.cpp @@ -317,7 +317,7 @@ if (ret < ADM_LOGIN_LEN) return ENODATA; } -if (admins->FindAdmin(login, &currAdmin)) +if (admins->Find(login, &currAdmin)) { // Admin not found state = confHdr;