[rygel] core: Create directory of database if not already existing
- From: Zeeshan Ali Khattak <zeeshanak src gnome org>
- To: svn-commits-list gnome org
- Subject: [rygel] core: Create directory of database if not already existing
- Date: Thu, 25 Jun 2009 15:47:05 +0000 (UTC)
commit 063fd8fe726e8086d1bd78477073e4a3b83ded38
Author: Jens Georg <mail jensge org>
Date: Tue Jun 23 00:08:03 2009 +0200
core: Create directory of database if not already existing
src/rygel/rygel-media-db.vala | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/src/rygel/rygel-media-db.vala b/src/rygel/rygel-media-db.vala
index 6347b48..0012380 100644
--- a/src/rygel/rygel-media-db.vala
+++ b/src/rygel/rygel-media-db.vala
@@ -119,6 +119,8 @@ public class Rygel.MediaDB : Object {
"SELECT count(upnp_id) from Object where Object.parent = ?";
private void open_db (string name) {
+ var dirname = Path.get_dirname (name);
+ DirUtils.create_with_parents (dirname, 0750);
var rc = Database.open (name, out this.db);
if (rc != Sqlite.OK) {
warning ("Failed to open database: %d, %s",
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]