mirror of
https://git.pwmt.org/pwmt/zathura.git
synced 2024-12-29 12:46:00 +01:00
Fix memory leak in zathura_page_widget_finalize
This commit is contained in:
parent
bbc8076bf8
commit
5d1a872217
1 changed files with 10 additions and 1 deletions
|
@ -137,11 +137,20 @@ zathura_page_widget_finalize(GObject* object)
|
|||
{
|
||||
ZathuraPage* widget = ZATHURA_PAGE(object);
|
||||
zathura_page_widget_private_t* priv = ZATHURA_PAGE_GET_PRIVATE(widget);
|
||||
|
||||
if (priv->surface != NULL) {
|
||||
cairo_surface_destroy(priv->surface);
|
||||
}
|
||||
|
||||
if (priv->search_results != NULL) {
|
||||
girara_list_free(priv->search_results);
|
||||
}
|
||||
|
||||
if (priv->links != NULL) {
|
||||
girara_list_free(priv->links);
|
||||
}
|
||||
|
||||
g_static_mutex_free(&(priv->lock));
|
||||
girara_list_free(priv->links);
|
||||
|
||||
G_OBJECT_CLASS(zathura_page_widget_parent_class)->finalize(object);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue