mirror of
https://git.pwmt.org/pwmt/zathura.git
synced 2025-01-16 03:25:51 +01:00
Drop zathura_db_free
Signed-off-by: Sebastian Ramacher <sebastian+dev@ramacher.at>
This commit is contained in:
parent
b895759e72
commit
b5dbe9ff6d
4 changed files with 4 additions and 19 deletions
|
@ -79,7 +79,7 @@ zathura_sqldatabase_new(const char* path)
|
|||
zathura_database_t* db = g_object_new(ZATHURA_TYPE_SQLDATABASE, "path", path, NULL);
|
||||
zathura_sqldatabase_private_t* priv = ZATHURA_SQLDATABASE_GET_PRIVATE(db);
|
||||
if (priv->session == NULL) {
|
||||
g_object_unref(db);
|
||||
g_object_unref(G_OBJECT(db));
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
|
10
database.c
10
database.c
|
@ -9,16 +9,6 @@ zathura_database_default_init(ZathuraDatabaseInterface* GIRARA_UNUSED(iface))
|
|||
{
|
||||
}
|
||||
|
||||
void
|
||||
zathura_db_free(zathura_database_t* db)
|
||||
{
|
||||
if (db == NULL) {
|
||||
return;
|
||||
}
|
||||
|
||||
g_object_unref(db);
|
||||
}
|
||||
|
||||
bool
|
||||
zathura_db_add_bookmark(zathura_database_t* db, const char* file,
|
||||
zathura_bookmark_t* bookmark)
|
||||
|
|
|
@ -50,13 +50,6 @@ struct _ZathuraDatabaseInterface
|
|||
|
||||
GType zathura_database_get_type(void);
|
||||
|
||||
/**
|
||||
* Free database instance.
|
||||
*
|
||||
* @param db The database instance to free.
|
||||
*/
|
||||
void zathura_db_free(zathura_database_t* db);
|
||||
|
||||
/**
|
||||
* Add or update bookmark in the database.
|
||||
*
|
||||
|
|
|
@ -287,7 +287,9 @@ zathura_free(zathura_t* zathura)
|
|||
girara_list_free(zathura->bookmarks.bookmarks);
|
||||
|
||||
/* database */
|
||||
zathura_db_free(zathura->database);
|
||||
if (zathura->database != NULL) {
|
||||
g_object_unref(G_OBJECT(zathura->database));
|
||||
}
|
||||
|
||||
/* free print settings */
|
||||
if (zathura->print.settings != NULL) {
|
||||
|
|
Loading…
Reference in a new issue