From: Junio C Hamano <gitster@pobox.com>
To: Stefan Beller <sbeller@google.com>
Cc: "git\@vger.kernel.org" <git@vger.kernel.org>
Subject: Re: [PATCH v2 3/4] apply: do not read from beyond a symbolic link
Date: Tue, 03 Feb 2015 12:31:58 -0800 [thread overview]
Message-ID: <xmqqiofirb29.fsf@gitster.dls.corp.google.com> (raw)
In-Reply-To: <CAGZ79kYkT_1cKgn8_JseHovnXoeO1Hi5FFPE9k7T6qDXLVY_FA@mail.gmail.com> (Stefan Beller's message of "Tue, 3 Feb 2015 11:44:26 -0800")
Stefan Beller <sbeller@google.com> writes:
> On Tue, Feb 3, 2015 at 11:37 AM, Junio C Hamano <gitster@pobox.com> wrote:
>> Stefan Beller <sbeller@google.com> writes:
>>
>>> On Mon, Feb 2, 2015 at 3:27 PM, Junio C Hamano <gitster@pobox.com> wrote:
>>>> + test_must_fail git apply --index patch
>>>> +
>>>> +'
>>>
>>> Is the empty line between the last test_must_fail and the closing `'`
>>> intentional?
>>
>> I think I just mimicked the previous existing one, but I can go with
>> the version without.
>
> It was really a honest question. I've seen and written and sent
> tests without such an ending empty line and it seemed to be ok.
It was a honest answer, too.
I see existing new-style tests [*1*] that have and/or lack the empty
line at the end of the command, and I do not have particular
preference either way. Having these variations did not bother me
too much, at least until now. We might want to make them consistent,
and the time to be careful is when we add new tests, so it was very
valid for you to bring it up against this patch. But I do not know
if we as the Git developer community have preference either way, and
I myself don't either, so...
[Footnote]
*1* The really ancient style we want to clean-up goes like
cmd for setup > expect
test_expect_success \
'title of the test' \
'command && more command &&
yet more command > actual &&
test_cmp expect actual'
cmd for cleanup
and we want them to read more like
test_expect_success 'title of the test' '
test_when_finished "cmd for cleanup" &&
cmd for setup >expect &&
command &&
more command &&
yet more command >actual &&
test_cmp expect actual
'
next prev parent reply other threads:[~2015-02-03 20:32 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-02 23:27 [PATCH v2 0/4] "git apply" safety Junio C Hamano
2015-02-02 23:27 ` [PATCH v2 1/4] apply: reject input that touches outside $cwd Junio C Hamano
2015-02-03 0:45 ` Jeff King
2015-02-03 0:50 ` Jeff King
2015-02-03 20:23 ` Junio C Hamano
2015-02-03 21:01 ` Jeff King
2015-02-03 21:23 ` Junio C Hamano
2015-02-03 21:24 ` Jeff King
2015-02-03 21:40 ` Junio C Hamano
2015-02-03 21:50 ` Jeff King
2015-02-03 22:11 ` Junio C Hamano
2015-02-03 5:56 ` Torsten Bögershausen
2015-02-02 23:27 ` [PATCH v2 2/4] apply: do not read from the filesystem under --index Junio C Hamano
2015-02-02 23:27 ` [PATCH v2 3/4] apply: do not read from beyond a symbolic link Junio C Hamano
2015-02-03 0:08 ` Stefan Beller
2015-02-03 19:37 ` Junio C Hamano
2015-02-03 19:44 ` Stefan Beller
2015-02-03 20:31 ` Junio C Hamano [this message]
2015-02-02 23:27 ` [PATCH v2 4/4] apply: do not touch a file " Junio C Hamano
2015-02-03 1:11 ` Jeff King
2015-02-03 1:56 ` Junio C Hamano
2015-02-03 2:04 ` Jeff King
2015-02-03 21:01 ` Junio C Hamano
2015-02-03 23:40 ` Eric Sunshine
2015-02-04 0:44 ` [PATCH v3 0/4] "git apply" safety Junio C Hamano
2015-02-04 0:44 ` [PATCH v3 1/4] apply: reject input that touches outside the working area Junio C Hamano
2015-02-04 0:44 ` [PATCH v3 2/4] apply: do not read from the filesystem under --index Junio C Hamano
2015-02-04 0:44 ` [PATCH v3 3/4] apply: do not read from beyond a symbolic link Junio C Hamano
2015-02-04 0:44 ` [PATCH v3 4/4] apply: do not touch a file " Junio C Hamano
2015-02-10 22:36 ` [PATCH v4 0/4] "git apply" safety Junio C Hamano
2015-02-10 22:36 ` [PATCH v4 1/4] apply: reject input that touches outside the working area Junio C Hamano
2015-02-10 22:36 ` [PATCH v4 2/4] apply: do not read from the filesystem under --index Junio C Hamano
2015-02-10 22:36 ` [PATCH v4 3/4] apply: do not read from beyond a symbolic link Junio C Hamano
2015-02-10 22:36 ` [PATCH v4 4/4] apply: do not touch a file " Junio C Hamano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqqiofirb29.fsf@gitster.dls.corp.google.com \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=sbeller@google.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.