[tracker] tracker: Don't unref manager in the loop in "tracker index -f" subcommand



commit 9a3a5baaddbc1e3d68eb134cf607c342de4e77f8
Author: Carlos Garnacho <carlosg gnome org>
Date:   Sun Jun 5 01:10:51 2016 +0200

    tracker: Don't unref manager in the loop in "tracker index -f" subcommand
    
    Must be unref'ed after the loop. Fixes crash if >1 files are provided.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=767024

 src/tracker/tracker-index.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/tracker/tracker-index.c b/src/tracker/tracker-index.c
index ae272f9..850fe2f 100644
--- a/src/tracker/tracker-index.c
+++ b/src/tracker/tracker-index.c
@@ -173,11 +173,11 @@ index_or_reindex_file (void)
                }
 
                g_print ("%s\n", _("(Re)indexing file was successful"));
-
-               g_object_unref (manager);
                g_object_unref (file);
        }
 
+       g_object_unref (manager);
+
        return EXIT_SUCCESS;
 }
 


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