From e690e668ba185445fc79a68a48ca42ed65eba9ef Mon Sep 17 00:00:00 2001 From: skodak Date: Wed, 9 Jul 2008 10:32:37 +0000 Subject: [PATCH] MDL-15469 adding fclose before write to already open file --- lib/setup.php | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/setup.php b/lib/setup.php index b8d9c6ee5a6..62406462973 100644 --- a/lib/setup.php +++ b/lib/setup.php @@ -161,6 +161,7 @@ global $HTTPSPAGEREQUIRED; if (file_exists($CFG->dataroot.'/emailcount')){ $fp = fopen($CFG->dataroot.'/emailcount', 'r'); $content = fread($fp, 24); + fclose($fp); if((time() - (int)$content) > 600){ mail($CFG->emailconnectionerrorsto, 'WARNING: Database connection error: '.$CFG->wwwroot,