public inbox for git@vger.kernel.org 
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox•com>
To: Thomas Rast <trast@student•ethz.ch>
Cc: Johannes Sixt <j.sixt@viscovery•net>, <git@vger•kernel.org>,
	Linus Torvalds <torvalds@linux-foundation•org>
Subject: Re: [PATCH] Handle double slashes in make_relative_path()
Date: Fri, 22 Jan 2010 15:35:27 -0800	[thread overview]
Message-ID: <7vpr51k91c.fsf@alter.siamese.dyndns.org> (raw)
In-Reply-To: <201001222211.14743.trast@student.ethz.ch> (Thomas Rast's message of "Fri\, 22 Jan 2010 22\:11\:14 +0100")

Thomas Rast <trast@student•ethz.ch> writes:

> It's not about *permitted* input; the problem is simply that the
> current function gives back *bogus* paths, which causes git to fail.
> So I only went for the minimal patch to fix this.

With that logic a minimal patch would have been not to call the function
at all, as apparently the caller seem to be able to cope with absolute
paths returned when they could be made relative, no?

In other words, it wasn't obvious to me if the minimal patch avoided
returning a bogus result claiming that is a path relative to the base
directory and instead returned an absolute path (which might be suboptimal
but way better than giving a wrong thing back) in _all_ cases, or only
just on _some_ cases but not others, and if it was the latter, what are
the cases that it did better than the original.

> As for your patch, thanks for coming up with a real fix.  I read the
> amended version, and it seems correct to me.

By "amended", I take it to mean the fix-up by Hannes.  I'll queue one
for 'maint'.

Thanks.

      reply	other threads:[~2010-01-22 23:35 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-01-22  0:07 [PATCH] Handle double slashes in make_relative_path() Thomas Rast
2010-01-22  1:40 ` Junio C Hamano
2010-01-22  3:05   ` Junio C Hamano
2010-01-22  8:36     ` Johannes Sixt
2010-01-23 11:40       ` Robin Rosenberg
2010-01-23 13:09         ` Johannes Sixt
2010-01-23 13:48           ` Robin Rosenberg
2010-01-23 19:00             ` Johannes Sixt
2010-01-23 20:04           ` Junio C Hamano
2010-01-23 20:14             ` Junio C Hamano
2010-01-23 20:41               ` Johannes Sixt
2010-01-23 21:01                 ` Sverre Rabbelier
2010-01-24 13:57                   ` Thomas Rast
2010-01-24 19:04                     ` Bernhard R. Link
2010-01-24 20:05                       ` Junio C Hamano
2010-01-24 16:44                 ` Johannes Sixt
2010-01-24 18:31                   ` Junio C Hamano
2010-01-25  1:06                     ` Robin Rosenberg
2010-01-22 21:11   ` Thomas Rast
2010-01-22 23:35     ` Junio C Hamano [this message]

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=7vpr51k91c.fsf@alter.siamese.dyndns.org \
    --to=gitster@pobox$(echo .)com \
    --cc=git@vger$(echo .)kernel.org \
    --cc=j.sixt@viscovery$(echo .)net \
    --cc=torvalds@linux-foundation$(echo .)org \
    --cc=trast@student$(echo .)ethz.ch \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox