]> git.cameronkatri.com Git - cgit.git/commitdiff
ui-blame: set repo for sb
authorJason A. Donenfeld <Jason@zx2c4.com>
Thu, 22 Nov 2018 00:49:55 +0000 (01:49 +0100)
committerJason A. Donenfeld <Jason@zx2c4.com>
Sun, 25 Nov 2018 05:01:34 +0000 (06:01 +0100)
Otherwise recent git complains and crashes with: "BUG: blame.c:1787:
repo is NULL".

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
ui-blame.c

index 6dc555fbd22b52651eda9afd7bcf245e464e37da..c52cb9b85f53750c655c5253018f2583e0efea80 100644 (file)
@@ -131,6 +131,7 @@ static void print_object(const struct object_id *oid, const char *path,
        setup_revisions(rev_argv.argc, rev_argv.argv, &revs, NULL);
        init_scoreboard(&sb);
        sb.revs = &revs;
        setup_revisions(rev_argv.argc, rev_argv.argv, &revs, NULL);
        init_scoreboard(&sb);
        sb.revs = &revs;
+       sb.repo = the_repository;
        setup_scoreboard(&sb, path, &o);
        o->suspects = blame_entry_prepend(NULL, 0, sb.num_lines, o);
        prio_queue_put(&sb.commits, o->commit);
        setup_scoreboard(&sb, path, &o);
        o->suspects = blame_entry_prepend(NULL, 0, sb.num_lines, o);
        prio_queue_put(&sb.commits, o->commit);