[gnome-photos/mnth/google-item-autoptr] google-item: Use g_autoptr*



commit a2264b5f5d2d4822aaea1269c2b9fa62b5864d18
Author: Yi-Soo An <yisooan gmail com>
Date:   Thu Feb 7 12:51:57 2019 +0900

    google-item: Use g_autoptr*
    
    https://gitlab.gnome.org/GNOME/gnome-photos/issues/77

 src/photos-google-item.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
---
diff --git a/src/photos-google-item.c b/src/photos-google-item.c
index 2bc74424..5737f958 100644
--- a/src/photos-google-item.c
+++ b/src/photos-google-item.c
@@ -108,7 +108,7 @@ photos_google_get_picasaweb_file (PhotosBaseItem *item, GCancellable *cancellabl
   PhotosSource *source;
   GDataAuthorizationDomain *authorization_domain;
   GDataEntry *entry;
-  GDataGoaAuthorizer *authorizer; /* TODO: use g_autoptr */
+  g_autoptr (GDataGoaAuthorizer) authorizer = NULL;
   g_autoptr (GDataPicasaWebQuery) query = NULL;
   g_autoptr (GDataPicasaWebService) service = NULL;
   const gchar *identifier;
@@ -132,7 +132,6 @@ photos_google_get_picasaweb_file (PhotosBaseItem *item, GCancellable *cancellabl
                                             cancellable,
                                             error);
 
-  g_object_unref (authorizer);
   return entry;
 }
 


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