From: Jacob Keller <jacob.keller@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: Eric Sunshine <sunshine@sunshineco.com>,
Jacob Keller <jacob.e.keller@intel.com>,
Git List <git@vger.kernel.org>
Subject: Re: [v4] refspec: add support for negative refspecs
Date: Wed, 30 Sep 2020 15:01:13 -0700 [thread overview]
Message-ID: <CA+P7+xqs4avU5y32jVMTRB8f0MJ8JjFoWE9mFffh7JrnCWaZMw@mail.gmail.com> (raw)
In-Reply-To: <xmqqr1qjexmg.fsf@gitster.c.googlers.com>
On Wed, Sep 30, 2020 at 2:57 PM Junio C Hamano <gitster@pobox.com> wrote:
>
> Eric Sunshine <sunshine@sunshineco.com> writes:
>
> > On Wed, Sep 30, 2020 at 5:26 PM Jacob Keller <jacob.e.keller@intel.com> wrote:
> >> Changes since v3
> >> * removed the ?: usage (for real this time)
> >>
> >> + /* Note the reversal of src and dst */
> >> + if (refspec->pattern) {
> >> + const char *key = refspec->dst ?: refspec->src;
> >
> > Blorp.
>
> Woof.
>
> Have squashed this in.
>
> remote.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
I sent a v5 too.. Lol
Clearly just not my day today
Thanks,
Jake
> diff --git a/remote.c b/remote.c
> index 9f8b25674e..dad3b79332 100644
> --- a/remote.c
> +++ b/remote.c
> @@ -750,7 +750,7 @@ static int query_matches_negative_refspec(struct refspec *rs, struct refspec_ite
>
> /* Note the reversal of src and dst */
> if (refspec->pattern) {
> - const char *key = refspec->dst ?: refspec->src;
> + const char *key = refspec->dst ? refspec->dst : refspec->src;
> const char *value = refspec->src;
>
> if (match_name_with_pattern(key, needle, value, &expn_name))
next prev parent reply other threads:[~2020-09-30 22:01 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-30 21:25 [v4] refspec: add support for negative refspecs Jacob Keller
2020-09-30 21:34 ` Eric Sunshine
2020-09-30 21:57 ` Junio C Hamano
2020-09-30 22:01 ` Jacob Keller [this message]
2020-09-30 22:00 ` Jacob Keller
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
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CA+P7+xqs4avU5y32jVMTRB8f0MJ8JjFoWE9mFffh7JrnCWaZMw@mail.gmail.com \
--to=jacob.keller@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=jacob.e.keller@intel.com \
--cc=sunshine@sunshineco.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.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).