store(st),
WriteServLog(GetStgLogger()),
searchDescriptors(),
- handle(0)
+ handle(0),
+ mutex(),
+ strError()
{
pthread_mutex_init(&mutex, NULL);
Read();
if (!priv->corpChg)
{
- string s = admin->GetLogStr() + " Add corporation \'" + corp.name + "\'. Access denied.";
+ std::string s = admin->GetLogStr() + " Add corporation \'" + corp.name + "\'. Access denied.";
strError = "Access denied.";
WriteServLog(s.c_str());
return -1;
return -1;
}
//-----------------------------------------------------------------------------
-int CORPORATIONS_IMPL::Del(const string & name, const ADMIN * admin)
+int CORPORATIONS_IMPL::Del(const std::string & name, const ADMIN * admin)
{
STG_LOCKER lock(&mutex, __FILE__, __LINE__);
const PRIV * priv = admin->GetPriv();
if (!priv->corpChg)
{
- string s = admin->GetLogStr() + " Delete corporation \'" + name + "\'. Access denied.";
+ std::string s = admin->GetLogStr() + " Delete corporation \'" + name + "\'. Access denied.";
strError = "Access denied.";
WriteServLog(s.c_str());
return -1;
return -1;
}
-map<int, const_crp_iter>::iterator csi;
+std::map<int, const_crp_iter>::iterator csi;
csi = searchDescriptors.begin();
while (csi != searchDescriptors.end())
{
if (!priv->corpChg)
{
- string s = admin->GetLogStr() + " Change corporation \'" + corp.name + "\'. Access denied.";
+ std::string s = admin->GetLogStr() + " Change corporation \'" + corp.name + "\'. Access denied.";
strError = "Access denied.";
WriteServLog(s.c_str());
return -1;
bool CORPORATIONS_IMPL::Read()
{
STG_LOCKER lock(&mutex, __FILE__, __LINE__);
-vector<string> corpsList;
+std::vector<std::string> corpsList;
if (store->GetCorpsList(&corpsList) < 0)
{
WriteServLog(store->GetStrError().c_str());
return false;
}
//-----------------------------------------------------------------------------
-bool CORPORATIONS_IMPL::Find(const string & name, CORP_CONF * corp)
+bool CORPORATIONS_IMPL::Find(const std::string & name, CORP_CONF * corp)
{
assert(corp != NULL && "Pointer to corporation is not null");
return true;
}
//-----------------------------------------------------------------------------
-bool CORPORATIONS_IMPL::Exists(const string & name) const
+bool CORPORATIONS_IMPL::Exists(const std::string & name) const
{
STG_LOCKER lock(&mutex, __FILE__, __LINE__);
if (data.empty())