This is an automated email from the git hooks/post-receive script.

bluesabre pushed a 
commit to branch 
master
in repository panel-plugins/xfce4-places-plugin.

commit bba2a39dae076b6e4d16ffd224de7a75b16c022f
Author: Andre Miranda <[email protected]>
Date:   Sat Apr 20 14:58:03 2019 -0300

    Fix runtime errors
---
 panel-plugin/model_user.c | 13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)

diff --git a/panel-plugin/model_user.c b/panel-plugin/model_user.c
index 7663b12..33a0a44 100644
--- a/panel-plugin/model_user.c
+++ b/panel-plugin/model_user.c
@@ -180,20 +180,25 @@ pbuser_build_bookmarks(PlacesBookmarkGroup 
*bookmark_group)
                                   G_FILE_ATTRIBUTE_STANDARD_ICON,
                                   0, NULL, NULL);
 
-            icon = g_file_info_get_icon(fileinfo);
+            if(fileinfo != NULL)
+                icon = g_file_info_get_icon(fileinfo);
+
             if(icon == NULL)
                 icon = g_themed_icon_new ("folder");
+
             g_object_ref(icon);
             p_uri = PLACES_URI_SCHEME_FILE;
 
             if(name == NULL) {
-                name = g_strdup(g_file_info_get_attribute_string(fileinfo,
-                                  G_FILE_ATTRIBUTE_STANDARD_DISPLAY_NAME));
+                if(fileinfo != NULL)
+                    name = g_strdup(g_file_info_get_attribute_string(fileinfo,
+                                    G_FILE_ATTRIBUTE_STANDARD_DISPLAY_NAME));
                 if(name == NULL)
                     name = g_strdup(g_filename_display_basename(uri));
             }
 
-            g_object_unref (G_OBJECT (fileinfo));
+            if(fileinfo != NULL)
+                g_object_unref (G_OBJECT (fileinfo));
 
         }else{
 

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.
_______________________________________________
Xfce4-commits mailing list
[email protected]
https://mail.xfce.org/mailman/listinfo/xfce4-commits

Reply via email to