Merge branch 'ab/test-must-be-empty'
[gitweb.git] / builtin / log.c
index 805f89d7e1552e86a8c2b990a0e213d09f91d42a..e094560d9abca6e819c24b845dc7c04d384850c3 100644 (file)
@@ -30,6 +30,7 @@
 #include "gpg-interface.h"
 #include "progress.h"
 #include "commit-slab.h"
+#include "repository.h"
 
 #define MAIL_DEFAULT_WRAP 72
 
@@ -619,7 +620,7 @@ int cmd_show(int argc, const char **argv, const char *prefix)
                        rev.shown_one = 1;
                        if (ret)
                                break;
-                       o = parse_object(&t->tagged->oid);
+                       o = parse_object(the_repository, &t->tagged->oid);
                        if (!o)
                                ret = error(_("Could not read object %s"),
                                            oid_to_hex(&t->tagged->oid));
@@ -906,8 +907,8 @@ static void get_patch_ids(struct rev_info *rev, struct patch_ids *ids)
        o2 = rev->pending.objects[1].item;
        flags1 = o1->flags;
        flags2 = o2->flags;
-       c1 = lookup_commit_reference(&o1->oid);
-       c2 = lookup_commit_reference(&o2->oid);
+       c1 = lookup_commit_reference(the_repository, &o1->oid);
+       c2 = lookup_commit_reference(the_repository, &o2->oid);
 
        if ((flags1 & UNINTERESTING) == (flags2 & UNINTERESTING))
                die(_("Not a range."));
@@ -1607,14 +1608,14 @@ int cmd_format_patch(int argc, const char **argv, const char *prefix)
                numbered = 0;
 
        if (numbered && keep_subject)
-               die (_("-n and -k are mutually exclusive."));
+               die(_("-n and -k are mutually exclusive"));
        if (keep_subject && subject_prefix)
-               die (_("--subject-prefix/--rfc and -k are mutually exclusive."));
+               die(_("--subject-prefix/--rfc and -k are mutually exclusive"));
        rev.preserve_subject = keep_subject;
 
        argc = setup_revisions(argc, argv, &rev, &s_r_opt);
        if (argc > 1)
-               die (_("unrecognized argument: %s"), argv[1]);
+               die(_("unrecognized argument: %s"), argv[1]);
 
        if (rev.diffopt.output_format & DIFF_FORMAT_NAME)
                die(_("--name-only does not make sense"));
@@ -1864,7 +1865,8 @@ static int add_pending_commit(const char *arg, struct rev_info *revs, int flags)
 {
        struct object_id oid;
        if (get_oid(arg, &oid) == 0) {
-               struct commit *commit = lookup_commit_reference(&oid);
+               struct commit *commit = lookup_commit_reference(the_repository,
+                                                               &oid);
                if (commit) {
                        commit->object.flags |= flags;
                        add_pending_object(revs, &commit->object, arg);