From 171addbc5977483b4c55fbe697fc7a5bf494be16 Mon Sep 17 00:00:00 2001 From: Lars Kneschke Date: Sun, 28 Sep 2003 10:32:12 +0000 Subject: [PATCH] use stream_set_timeout only with php 4.3.0 and above --- phpgwapi/inc/class.network.inc.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/phpgwapi/inc/class.network.inc.php b/phpgwapi/inc/class.network.inc.php index f0ccdd7676..83aee3165c 100644 --- a/phpgwapi/inc/class.network.inc.php +++ b/phpgwapi/inc/class.network.inc.php @@ -75,12 +75,12 @@ } break; } - if(floor(phpversion()) == 4) + if(version_compare(phpversion(),'4.3.0') >= 0) { $this->socket = fsockopen($server,$port,$errcode,$errmsg,$timeout); if($this->socket) { - socket_set_timeout($this->socket,$timeout,0); + stream_set_timeout($this->socket,$timeout,0); } } else