Re: [PATCH 2/2] WIP per-path attribute based hunk header selection.

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

 



Hi,

On Wed, 4 Jul 2007, Junio C Hamano wrote:

> diff --git a/diff.c b/diff.c
> index 552f7c0..0c7d2c6 100644
> --- a/diff.c
> +++ b/diff.c
> @@ -3011,21 +3079,6 @@ void diffcore_std(struct diff_options *options)
>  	if (options->quiet)
>  		return;
>  
> -	/*
> -	 * break/rename count similarity differently depending on
> -	 * the binary-ness.
> -	 */
> -	if ((options->break_opt != -1) || (options->detect_rename)) {
> -		struct diff_queue_struct *q = &diff_queued_diff;
> -		int i;
> -
> -		for (i = 0; i < q->nr; i++) {
> -			struct diff_filepair *p = q->queue[i];
> -			p->one->is_binary = file_is_binary(p->one);
> -			p->two->is_binary = file_is_binary(p->two);
> -		}
> -	}
> -
>  	if (options->break_opt != -1)
>  		diffcore_break(options->break_opt);
>  	if (options->detect_rename)
> diff --git a/diffcore-delta.c b/diffcore-delta.c
> index a038b16..d9729e5 100644
> --- a/diffcore-delta.c
> +++ b/diffcore-delta.c
> @@ -129,7 +129,7 @@ static struct spanhash_top *hash_chars(struct diff_filespec *one)
>  	struct spanhash_top *hash;
>  	unsigned char *buf = one->data;
>  	unsigned int sz = one->size;
> -	int is_text = !one->is_binary;
> +	int is_text = !diff_filespec_is_binary(one);
>  
>  	i = INITIAL_HASH_SIZE;
>  	hash = xmalloc(sizeof(*hash) + sizeof(struct spanhash) * (1<<i));

It is quite cute to hide this in the funcname patch...

Ciao,
Dscho

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

  Powered by Linux