Re: [PATCH] graph API: fix bug in graph_is_interesting()

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

 



Adam Simpkins <simpkins@xxxxxxxxxxxx> writes:

> -enum commit_action simplify_commit(struct rev_info *revs, struct commit *commit)
> +enum commit_action get_commit_action(struct rev_info *revs, struct commit *commit)
>  {
>  	if (commit->object.flags & SHOWN)
>  		return commit_ignore;
> @@ -1692,12 +1692,21 @@ enum commit_action simplify_commit(struct rev_info *revs, struct commit *commit)
>  			if (!commit->parents || !commit->parents->next)
>  				return commit_ignore;
>  		}
> -		if (want_ancestry(revs) && rewrite_parents(revs, commit) < 0)
> -			return commit_error;
>  	}
>  	return commit_show;
>  }
>  
> +enum commit_action simplify_commit(struct rev_info *revs, struct commit *commit)
> +{
> +	enum commit_action action = get_commit_action(revs, commit);
> +
> +	if (action == commit_show && revs->prune && revs->dense && want_ancestry(revs)) {
> +		if (rewrite_parents(revs, commit) < 0)
> +			return commit_error;
> +	}
> +	return action;
> +}

When simplify_commit() logic (now called get_comit_action()) decides to
show this commit because revs->show_all was specified, we did not rewrite
its parents, but now we will?


--
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]