From d4ea4f2056a2863c7a37ad83e73bb63301de5022 Mon Sep 17 00:00:00 2001 From: rootavish Date: Fri, 25 Jul 2014 18:32:19 +0530 Subject: Fixing dispose functions, display in webview Fixed the backend epub_document_finalize function which was caused caja to crash when you opened the document properties dialog. Fixed the ev_window_dispose and the webview's dispose and finalise functions, now the window closes without any glib-critical errors. Also now it is possible to read epub documents, once you have changed pages at least once, I still have to figure out where I call load_uri at document load. --- backend/epub/epub-document.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'backend/epub') diff --git a/backend/epub/epub-document.c b/backend/epub/epub-document.c index 0801c3ab..a107b710 100644 --- a/backend/epub/epub-document.c +++ b/backend/epub/epub-document.c @@ -949,20 +949,23 @@ epub_document_finalize (GObject *object) if (epub_remove_temporary_dir (epub_document->tmp_archive_dir) == -1) g_warning (_("There was an error deleting ā€œ%sā€."), epub_document->tmp_archive_dir); - g_free (epub_document->tmp_archive_dir); } if ( epub_document->contentList ) { g_list_free_full(epub_document->contentList,(GDestroyNotify)free_tree_nodes); + epub_document->contentList = NULL; } if ( epub_document->tmp_archive_dir) { g_free (epub_document->tmp_archive_dir); + epub_document->tmp_archive_dir = NULL; } if ( epub_document->archivename) { g_free (epub_document->archivename); + epub_document->archivename = NULL; } if ( epub_document->documentdir) { g_free (epub_document->documentdir); + epub_document->documentdir = NULL; } G_OBJECT_CLASS (epub_document_parent_class)->finalize (object); } -- cgit v1.2.1