From: Roland Häder Date: Sat, 28 Feb 2009 23:46:35 +0000 (+0000) Subject: SQL_IS_LINK_UP() aborts if wether no resource or null is given X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=commitdiff_plain;h=e0f29b44879d7aba8e9b7c95b248910375c2312a;ds=sidebyside SQL_IS_LINK_UP() aborts if wether no resource or null is given --- diff --git a/inc/db/lib-mysql3.php b/inc/db/lib-mysql3.php index c98de977be..10372a4a3b 100644 --- a/inc/db/lib-mysql3.php +++ b/inc/db/lib-mysql3.php @@ -385,6 +385,12 @@ function SQL_GET_LINK () { // Setter for link function SQL_SET_LINK ($link) { + // Is this a resource or null? + if ((!is_resource($link)) && (!is_null($link))) { + // This should never happen! + trigger_error(sprintf("link is not resource or null. Type: %s", gettype($link))); + } // END - if + // Set it $GLOABLS['sql_link'] = $link; }