Re: [PATCH] Improve parent blame to detect renames by using the previous information

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

 



On Sun, Jun 6, 2010 at 18:35, Jeff King <peff@xxxxxxxx> wrote:
>
> On Sat, Jun 05, 2010 at 03:56:05PM -0400, Jonas Fonseca wrote:
>
> One minor bug:
>
> > @@ -5204,10 +5148,13 @@ blame_request(struct view *view, enum request request, struct line *line)
> >               break;
> >
> >       case REQ_PARENT:
> > -             if (check_blame_commit(blame, TRUE) &&
> > -                 select_commit_parent(blame->commit->id, opt_ref,
> > -                                      blame->commit->filename)) {
> > -                     string_copy(opt_file, blame->commit->filename);
> > +             if (!check_blame_commit(blame, TRUE))
> > +                     break;
> > +             if (!*blame->commit->parent_id) {
> > +                     report("The selected commit has no parents");
> > +             } else {
> > +                     string_copy_rev(opt_ref, blame->commit->parent_id);
> > +                     string_copy_rev(opt_file, blame->commit->parent_filename);
>
> This second string_copy_rev should be a string_ncopy, shouldn't it?

Oh, yes, a regular copy and paste bug. Thanks for noticing. I will
include this and consider tagging another release.

--
Jonas Fonseca
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]