Re: [PATCH 63/83] builtin/apply: make apply_all_patches() return -1 on error

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

 



On Sun, May 1, 2016 at 11:03 PM, Eric Sunshine <sunshine@xxxxxxxxxxxxxx> wrote:
>> @@ -4590,10 +4590,10 @@ static int apply_all_patches(struct apply_state *state,
>>                                 squelched);
>>                 }
>>                 if (state->ws_error_action == die_on_ws_error)
>> -                       die(Q_("%d line adds whitespace errors.",
>> -                              "%d lines add whitespace errors.",
>> -                              state->whitespace_error),
>> -                           state->whitespace_error);
>> +                       return error(Q_("%d line adds whitespace errors.",
>> +                                       "%d lines add whitespace errors.",
>> +                                       state->whitespace_error),
>> +                                    state->whitespace_error);
>
> How does this new 'return' relate to the logic below which updates the
> index? Does the index need to be updated here now too?

I think it is the right thing to do not to update the index when there
are whitespaces and state->ws_error_action == die_on_ws_error.
--
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]