From: Aaron Schulz Date: Thu, 13 Aug 2009 21:18:37 +0000 (+0000) Subject: Follow-up r54966: more sanity checks X-Git-Tag: 1.31.0-rc.0~40321 X-Git-Url: http://git.cyclocoop.org//%22javascript:ModifierStyle%28%27%22.%24id.%22%27%29/%22?a=commitdiff_plain;h=6dd212d5be3d154062155431d592ec49d3cf26d3;p=lhc%2Fweb%2Fwiklou.git Follow-up r54966: more sanity checks --- diff --git a/includes/Cdb.php b/includes/Cdb.php index e7c2c00b8a..ab429872d1 100644 --- a/includes/Cdb.php +++ b/includes/Cdb.php @@ -98,7 +98,8 @@ class CdbReader_DBA { } function close() { - dba_close( $this->handle ); + if( isset($this->handle) ) + dba_close( $this->handle ); unset( $this->handle ); } @@ -128,7 +129,8 @@ class CdbWriter_DBA { } function close() { - dba_close( $this->handle ); + if( isset($this->handle) ) + dba_close( $this->handle ); if ( wfIsWindows() ) { unlink( $this->realFileName ); }