[ostree] core: Fix crasher in "rev-parse"



commit eb4302517f6b62eca1a898aa0fb3e3a76ba46d59
Author: Colin Walters <walters verbum org>
Date:   Thu Mar 8 08:41:01 2012 -0500

    core: Fix crasher in "rev-parse"

 src/ostree/ot-builtin-rev-parse.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
---
diff --git a/src/ostree/ot-builtin-rev-parse.c b/src/ostree/ot-builtin-rev-parse.c
index 5d4bf73..8427386 100644
--- a/src/ostree/ot-builtin-rev-parse.c
+++ b/src/ostree/ot-builtin-rev-parse.c
@@ -62,6 +62,7 @@ ostree_builtin_rev_parse (int argc, char **argv, GFile *repo_path, GError **erro
     {
       rev = argv[i];
       g_free (resolved_rev);
+      resolved_rev = NULL;
       if (!ostree_repo_resolve_rev (repo, rev, FALSE, &resolved_rev, error))
         goto out;
       g_print ("%s\n", resolved_rev);



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