aboutsummaryrefslogtreecommitdiffstats
path: root/src/database.h
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2009-01-04 21:18:16 +0100
committerMax Kellermann <max@duempel.org>2009-01-04 21:18:16 +0100
commit82166b715c2e8b39eb20d179c95aa982335ad07c (patch)
tree2a66426ae0db1fede2649d61f465ba20f1830812 /src/database.h
parent6acba7350938c099afab7bec04c8dc9adf674424 (diff)
downloadmpd-82166b715c2e8b39eb20d179c95aa982335ad07c.tar.gz
mpd-82166b715c2e8b39eb20d179c95aa982335ad07c.tar.xz
mpd-82166b715c2e8b39eb20d179c95aa982335ad07c.zip
database: db_init() initializes library, does not update
For updating the database, directory_update_init() should be called explicitly.
Diffstat (limited to 'src/database.h')
-rw-r--r--src/database.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/database.h b/src/database.h
index b6884b604..238ddb374 100644
--- a/src/database.h
+++ b/src/database.h
@@ -24,12 +24,25 @@
struct directory;
+/**
+ * Initialize the database library.
+ */
void
db_init(void);
void
db_finish(void);
+/**
+ * Clear the database.
+ */
+static inline void
+db_clear(void)
+{
+ db_finish();
+ db_init();
+}
+
struct directory *
db_get_root(void);