summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--it_url.class2
1 files changed, 2 insertions, 0 deletions
diff --git a/it_url.class b/it_url.class
index 976dceb..7873a1a 100644
--- a/it_url.class
+++ b/it_url.class
@@ -109,6 +109,8 @@ function is_reachable($timeout = 5)
*/
function get($p=null, $timeout=5)
{
+ if (!is_int($timeout))
+ it::error("Wrong value for second argument of it_url::get()!");
if (!is_array($p))
$p = array('url' => $p, 'timeout' => $timeout);
$p += array('retries' => 1, 'curl' => true);