git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff King <peff@peff.net>
To: "Björn Kautler" <Bjoern@kautler.net>
Cc: git@vger.kernel.org
Subject: Re: fast-import should fail on invalid unsupported paths
Date: Mon, 18 Mar 2019 17:17:38 -0400	[thread overview]
Message-ID: <20190318211737.GC29661@sigill.intra.peff.net> (raw)
In-Reply-To: <CAKChYSo9x5k0Ly2CNs5tbZ+jMdxBmDLZ9gm_645pwXZsCQ4ySg@mail.gmail.com>

On Mon, Mar 18, 2019 at 06:28:16PM +0100, Björn Kautler wrote:

> I think fast-import should refuse to import paths Git cannot handle
> properly later on, so that the migration fails early and the frontend
> that generates the fast-import stream can be fixed / configured to not
> include such invalid paths.

Yeah, that seems quite sensible to me[1].

If you (or anybody else) are interested in working on this, I suspect
the answer is to just sprinkle some calls to verify_path() in the right
spots. Probably in fast-import.c:file_change_m(), etc.

-Peff

[1] Stretching to think of a way this might backfire, I guess somebody
    could be using Git as an intermediate format to then convert to
    another system. But that seems terribly obscure, and at most I think
    we should give that case an escape hatch to disable the check; it
    should definitely be on by default.

  reply	other threads:[~2019-03-18 21:17 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-18 17:28 fast-import should fail on invalid unsupported paths Björn Kautler
2019-03-18 21:17 ` Jeff King [this message]
2023-04-14 11:54   ` Björn Kautler

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=20190318211737.GC29661@sigill.intra.peff.net \
    --to=peff@peff.net \
    --cc=Bjoern@kautler.net \
    --cc=git@vger.kernel.org \
    /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 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 NNTP newsgroup(s).