more memory cleanup

This commit is contained in:
Sebastian Ramacher 2010-12-11 10:06:43 +01:00
parent 4bf5718349
commit 0ab36aab2e

View File

@ -4005,8 +4005,16 @@ cb_destroy(GtkWidget* widget, gpointer data)
if(Zathura.PDF.document) if(Zathura.PDF.document)
close_file(FALSE); close_file(FALSE);
/* clean up other variables */ /* clean up bookmarks */
g_free(Zathura.Bookmarks.file); g_free(Zathura.Bookmarks.file);
if (Zathura.Bookmarks.data)
g_key_file_free(Zathura.Bookmarks.data);
/* destroy mutexes */
g_static_mutex_free(&(Zathura.Lock.pdflib_lock));
g_static_mutex_free(&(Zathura.Lock.search_lock));
g_static_mutex_free(&(Zathura.Lock.pdf_obj_lock));
g_static_mutex_free(&(Zathura.Lock.select_lock));
/* inotify */ /* inotify */
if(Zathura.FileMonitor.monitor) if(Zathura.FileMonitor.monitor)