From: Andreas Unterkircher Date: Sat, 15 Dec 2007 13:32:40 +0000 (+0000) Subject: issue81, check if f-spot database is writeable X-Git-Tag: phpfspot-1.2~24 X-Git-Url: https://git.nubati.net/cgi-bin/gitweb.cgi?p=phpfspot.git;a=commitdiff_plain;h=39507eea2eedc1d05d5467ebd14ea8ed8e7c9032;ds=sidebyside issue81, check if f-spot database is writeable git-svn-id: file:///var/lib/svn/phpfspot/trunk@315 fa6a889d-dae6-447d-9e79-4ba9a3039384 --- diff --git a/phpfspot.class.php b/phpfspot.class.php index ffd7e7e..e2b24a8 100644 --- a/phpfspot.class.php +++ b/phpfspot.class.php @@ -54,6 +54,10 @@ class PHPFSPOT { } $this->db = new PHPFSPOT_DB($this, $this->cfg->fspot_db); + if(!is_writeable($this->cfg->fspot_db)) { + print $this->cfg->fspot_db ." is not writeable for user ". $this->getuid() ."\n"; + exit(1); + } if(!is_writeable(dirname($this->cfg->phpfspot_db))) { print dirname($this->cfg->phpfspot_db) .": directory is not writeable!";