diff --git a/pandora_agents/ChangeLog b/pandora_agents/ChangeLog index 9b06989f94..707e1ae301 100644 --- a/pandora_agents/ChangeLog +++ b/pandora_agents/ChangeLog @@ -1,3 +1,8 @@ +2008-12-24 Ramon Novoa + + * win32/pandora_windows_service.cc: Do not send XML if server address + is not set. + 2008-12-16 Ramon Novoa * win32/modules/pandora_module_wmiquery.cc, diff --git a/pandora_agents/win32/pandora_windows_service.cc b/pandora_agents/win32/pandora_windows_service.cc index d401f496a9..81dea37209 100644 --- a/pandora_agents/win32/pandora_windows_service.cc +++ b/pandora_agents/win32/pandora_windows_service.cc @@ -742,11 +742,17 @@ Pandora_Windows_Service::sendXml (Pandora_Module_List *modules) { void Pandora_Windows_Service::pandora_run () { + Pandora_Agent_Conf *conf = NULL; + string server_addr; + pandoraDebug ("Run begin"); /* Check for configuration changes */ this->checkConfig (); + conf = this->getConf (); + server_addr = conf->getValue ("server_ip"); + execution_number++; if (this->modules != NULL) { @@ -768,8 +774,9 @@ Pandora_Windows_Service::pandora_run () { if (this->elapsed_transfer_time >= this->transfer_interval) { this->elapsed_transfer_time = 0; - - this->sendXml (this->modules); + if (!server_addr.empty ()) { + this->sendXml (this->modules); + } } /* Get the interval value (in minutes) */