diff options
author | rbuj <[email protected]> | 2021-11-08 19:25:05 +0100 |
---|---|---|
committer | Robert Antoni Buj Gelonch <[email protected]> | 2021-12-31 12:50:35 +0100 |
commit | 81be5c9b24dcceb65d4a974744d59e05b07583d9 (patch) | |
tree | 9e1e115f0c686ef063da2ff62a7624e5edf91ba9 /src | |
parent | d13f977a8c9b8701579199e888c2436bc00959a2 (diff) | |
download | caja-81be5c9b24dcceb65d4a974744d59e05b07583d9.tar.bz2 caja-81be5c9b24dcceb65d4a974744d59e05b07583d9.tar.xz |
fm-directory-view: fix memory leak
Diffstat (limited to 'src')
-rw-r--r-- | src/file-manager/fm-directory-view.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/file-manager/fm-directory-view.c b/src/file-manager/fm-directory-view.c index 8ba1050d..ddaa334c 100644 --- a/src/file-manager/fm-directory-view.c +++ b/src/file-manager/fm-directory-view.c @@ -4707,6 +4707,7 @@ reset_open_with_menu (FMDirectoryView *view, GList *selection) GtkUIManager *ui_manager; GtkAction *action; GAppInfo *default_app; + char *uri; /* Clear any previous inserted items in the applications and viewers placeholders */ @@ -4787,12 +4788,15 @@ reset_open_with_menu (FMDirectoryView *view, GList *selection) } /* Show open parent folder action if we are in search mode */ - if (eel_uri_is_search (fm_directory_view_get_uri (view)) && g_list_length (selection) == 1) + uri = fm_directory_view_get_uri (view); + if (eel_uri_is_search (uri) && g_list_length (selection) == 1) add_parent_folder_to_open_menu (view, selection, FM_DIRECTORY_VIEW_MENU_PATH_OPEN, FM_DIRECTORY_VIEW_POPUP_PATH_OPEN); + g_free (uri); + open_with_chooser_visible = other_applications_visible && g_list_length (selection) == 1; |