X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/086e44c60b861d665fe2a3e1cd7d691201e91c8c..d1d9452a687184ac6b992fadc77e89c8a308e388:/projects/stargazer/plugins/configuration/sgconfig/parser_admin.cpp diff --git a/projects/stargazer/plugins/configuration/sgconfig/parser_admin.cpp b/projects/stargazer/plugins/configuration/sgconfig/parser_admin.cpp index b1285a77..d93b3448 100644 --- a/projects/stargazer/plugins/configuration/sgconfig/parser_admin.cpp +++ b/projects/stargazer/plugins/configuration/sgconfig/parser_admin.cpp @@ -45,17 +45,16 @@ answerList->push_back(""); ADMIN_CONF ac; int h = admins->OpenSearch(); -unsigned int p; while (admins->SearchNext(h, &ac) == 0) { //memcpy(&p, &ac.priv, sizeof(unsigned int)); - p = (ac.priv.userStat << 0) + - (ac.priv.userConf << 2) + - (ac.priv.userCash << 4) + - (ac.priv.userPasswd << 6) + - (ac.priv.userAddDel << 8) + - (ac.priv.adminChg << 10) + - (ac.priv.tariffChg << 12); + unsigned int p = (ac.priv.userStat << 0) + + (ac.priv.userConf << 2) + + (ac.priv.userCash << 4) + + (ac.priv.userPasswd << 6) + + (ac.priv.userAddDel << 8) + + (ac.priv.adminChg << 10) + + (ac.priv.tariffChg << 12); strprintf(&s, "", ac.login.c_str(), p); answerList->push_back(s); } @@ -105,20 +104,6 @@ else } } //----------------------------------------------------------------------------- -int PARSER_DEL_ADMIN::CheckAttr(const char **attr) -{ -/* - * attr[0] = "login" (word login) - * attr[1] = login, value of login - * attr[2] = NULL */ - -if (strcasecmp(attr[0], "login") == 0 && attr[1] && !attr[2]) - { - return 0; - } -return -1; -} -//----------------------------------------------------------------------------- // ADD ADMIN //----------------------------------------------------------------------------- int PARSER_ADD_ADMIN::ParseStart(void *, const char *el, const char **attr)