Radish alpha
H
HardenedBSD Package Manager
Radicle
Git (anonymous pull)
Log in to clone via SSH
Don't try and init the DB every time
Matthew Seaman committed 13 years ago
commit 6a0c2fd25bd7cee7a38c08948a0e46a67ad87bca
parent 031cb1068e3176803c8ec7ea4dfff7370e87a7ac
1 file changed +2 -1
modified libpkg/pkgdb.c
@@ -760,7 +760,7 @@ pkgdb_open(struct pkgdb **db_p, pkgdb_t type)
		sqlite3_busy_timeout(db->sqlite, 5000);

		/* If the database is missing we have to initialize it */
-
		if (create == true)
+
		if (create == true) {
			if (mkdirs(dbdir) != EPKG_OK) {
				pkgdb_close(db);
				return (EPKG_FATAL);
@@ -769,6 +769,7 @@ pkgdb_open(struct pkgdb **db_p, pkgdb_t type)
				pkgdb_close(db);
				return (EPKG_FATAL);
			}
+
		}

		/* Create our functions */
		sqlcmd_init(db->sqlite, NULL, NULL);