mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-31 01:35:36 +02:00
Merge branch '695-nombre-de-agente-con-espacios-en-windows-ext-3657-v6-0' into 'pandora_6.0'
Remove leading and trailing double quotes from agent_name. Ref See merge request !440
This commit is contained in:
commit
12d26c8568
@ -1442,6 +1442,10 @@ Pandora_Windows_Service::checkAgentName(string filename){
|
||||
pos = buffer.find("agent_name");
|
||||
if (pos != string::npos){
|
||||
name_agent = buffer.substr(pos+11);
|
||||
if (name_agent.at(0) == '"' && name_agent.at(name_agent.size() - 1) == '"') {
|
||||
name_agent.erase(0, 1);
|
||||
name_agent.erase(name_agent.size() - 1, 1);
|
||||
}
|
||||
return name_agent;
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user