[gnome-photos/wip/rishi/view-container-g_auto] view-container: Use g_auto*




commit 0510aa2ce1f0e8fe3d66a61b52dfd9aa2a8c34cb
Author: Debarshi Ray <debarshir gnome org>
Date:   Wed Apr 7 00:10:33 2021 +0200

    view-container: Use g_auto*
    
    https://gitlab.gnome.org/GNOME/gnome-photos/issues/77

 src/photos-view-container.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
---
diff --git a/src/photos-view-container.c b/src/photos-view-container.c
index 403a99b3..917b57a5 100644
--- a/src/photos-view-container.c
+++ b/src/photos-view-container.c
@@ -241,14 +241,13 @@ static void
 photos_view_container_selection_changed (PhotosViewContainer *self)
 {
   GList *selected_urns;
-  GList *selection;
+  g_autolist (GdMainBoxItem) selection = NULL;
 
   selection = gd_main_box_get_selection (GD_MAIN_BOX (self->view));
   selected_urns = photos_utils_get_urns_from_items (selection);
   photos_selection_controller_set_selection (self->sel_cntrlr, selected_urns);
 
   g_list_free_full (selected_urns, g_free);
-  g_list_free_full (selection, g_object_unref);
 }
 
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]