From b1bdfbb9dce7e5ac7220894275737b1ca5823616 Mon Sep 17 00:00:00 2001 From: Ramon Novoa Date: Wed, 1 Oct 2008 11:17:33 +0000 Subject: [PATCH] 2008-10-01 Ramon Novoa * extensions/update_manager/lib/libupdate_manager_client.php: Added a timeout to the XML-RPC client. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@1125 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f --- pandora_console/ChangeLog | 5 +++++ .../update_manager/lib/libupdate_manager_client.php | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index 6934c14734..9d0411cd2b 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,8 @@ +2008-10-01 Ramon Novoa + + * extensions/update_manager/lib/libupdate_manager_client.php: Added a + timeout to the XML-RPC client. + 2008-09-30 Evi Vanoost * operation/reporting/reporting_xml.php: Reporting does now output XML diff --git a/pandora_console/extensions/update_manager/lib/libupdate_manager_client.php b/pandora_console/extensions/update_manager/lib/libupdate_manager_client.php index 6e6b0e4843..acd93a6250 100644 --- a/pandora_console/extensions/update_manager/lib/libupdate_manager_client.php +++ b/pandora_console/extensions/update_manager/lib/libupdate_manager_client.php @@ -22,13 +22,14 @@ unset ($prev_level); define ('XMLRPC_DEBUG', 0); +define ('XMLRPC_TIMEOUT', 5); function um_xml_rpc_client_call ($server_host, $server_path, $server_port, $proxy, $proxy_port, $proxy_user, $proxy_pass, $function, $parameters) { $msg = new XML_RPC_Message ($function, $parameters); $client = new XML_RPC_Client ($server_path, $server_host, $server_port, $proxy, $proxy_port, $proxy_user, $proxy_pass); if (defined ('XMLRPC_DEBUG')) $client->setDebug (XMLRPC_DEBUG); - $result = $client->send ($msg); + $result = $client->send ($msg, XMLRPC_TIMEOUT); if (! $result) { trigger_error ('Open Update Manager Server comunication error. '.$client->errstr);