Loading src/admin.cpp +10 −9 Changes for src/admin.cpp: 10 added lines, 9 removed lines. Original line number Diff line number Diff line Loading @@ -1810,22 +1810,23 @@ namespace authdb { gpodat.getAlowed(allow); size_t rd=sizeof(AuthHeader),end=backend->end(); std::shared_ptr<AuthData::Record> cur=std::make_shared<AuthData::Record>(); try{ while(rd<end){ AuthData::Record cur; backend->setPos(rd); backend->read((unsigned char*)&cur,sizeof(AuthData::Record)); rd=backend->getPos()+cur.datasize; if(cur.type == GroupData && strcmp(cur.fieldname,"groupname")==0){ cur.data = new char[cur.datasize]; backend->read((unsigned char*)cur.data,cur.datasize); rd=backend->getPos()+cur->datasize; if(cur->type == GroupData && strcmp(cur->fieldname,"groupname")==0){ cur->data = new char[cur->datasize]; backend->read((unsigned char*)cur->data,cur->datasize); char curcuid[255];; uuid_unparse(cur.uuid,curcuid); uuid_unparse(cur->uuid,curcuid); libhtmlpp::HtmlElement opt("option"); libhtmlpp::TextElement optname(cur.data) ; libhtmlpp::TextElement optname(cur->data) ; opt.setAttribute("value",curcuid); Loading @@ -1835,7 +1836,7 @@ namespace authdb { bool found=false; for(size_t i = 0; i < allow.count; ++i){ if( uuid_compare(cur.uuid,allow.uid[i])==0 ){ if( uuid_compare(cur->uuid,allow.uid[i])==0 ){ found=true; groupel->appendChild(&opt); break; Loading @@ -1844,7 +1845,7 @@ namespace authdb { if(!found) ngroupel->appendChild(&opt); delete[] cur.data; delete[] cur->data; } } }catch(AuthBackendError &e){ Loading Loading
src/admin.cpp +10 −9 Changes for src/admin.cpp: 10 added lines, 9 removed lines. Original line number Diff line number Diff line Loading @@ -1810,22 +1810,23 @@ namespace authdb { gpodat.getAlowed(allow); size_t rd=sizeof(AuthHeader),end=backend->end(); std::shared_ptr<AuthData::Record> cur=std::make_shared<AuthData::Record>(); try{ while(rd<end){ AuthData::Record cur; backend->setPos(rd); backend->read((unsigned char*)&cur,sizeof(AuthData::Record)); rd=backend->getPos()+cur.datasize; if(cur.type == GroupData && strcmp(cur.fieldname,"groupname")==0){ cur.data = new char[cur.datasize]; backend->read((unsigned char*)cur.data,cur.datasize); rd=backend->getPos()+cur->datasize; if(cur->type == GroupData && strcmp(cur->fieldname,"groupname")==0){ cur->data = new char[cur->datasize]; backend->read((unsigned char*)cur->data,cur->datasize); char curcuid[255];; uuid_unparse(cur.uuid,curcuid); uuid_unparse(cur->uuid,curcuid); libhtmlpp::HtmlElement opt("option"); libhtmlpp::TextElement optname(cur.data) ; libhtmlpp::TextElement optname(cur->data) ; opt.setAttribute("value",curcuid); Loading @@ -1835,7 +1836,7 @@ namespace authdb { bool found=false; for(size_t i = 0; i < allow.count; ++i){ if( uuid_compare(cur.uuid,allow.uid[i])==0 ){ if( uuid_compare(cur->uuid,allow.uid[i])==0 ){ found=true; groupel->appendChild(&opt); break; Loading @@ -1844,7 +1845,7 @@ namespace authdb { if(!found) ngroupel->appendChild(&opt); delete[] cur.data; delete[] cur->data; } } }catch(AuthBackendError &e){ Loading