zsh-workers
 help / color / mirror / code / Atom feed
From: Bart Schaefer <schaefer@brasslantern.com>
To: zsh-workers@zsh.org
Subject: Re: segfault with exceedingly long path
Date: Sun, 19 Jan 2014 16:02:38 -0800	[thread overview]
Message-ID: <140119160238.ZM5850@torch.brasslantern.com> (raw)
In-Reply-To: <20140119221310.GA502@ruderich.org>

On Jan 19, 11:13pm, Simon Ruderich wrote:
}
} So we could do that in small steps, e.g. first chdir(2) to a
} directory < PATH_MAX bytes deep, then from there to the next
} directory < PATH_MAX bytes deep and so on until we get down to
} the real directory.

Yes, but that doesn't even begin to address all the other places
where very long paths become an issue.  Would redirections have to
implcitly chdir along the pathname until they got "close enough"
to pass the path tail to open()?  Can you put a ridiculously long
path into $path or $fpath or $module_path?  $TMPPREFIX?  $ZDOTDIR?
What does [[ -d $longpath ]] do?  zstat $longpath?  ${(A)longpath}?

Can you even do an execve() when $#PWD is longer than PATH_MAX?

I don't think we want to let this can of worms out of Pandora's box,
or we'll be chasing geese until the cows come home to roost.


  reply	other threads:[~2014-01-20  0:02 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-18  0:20 Axel Beckert
2014-01-18  1:49 ` Bart Schaefer
2014-01-18  9:11   ` Axel Beckert
2014-01-19 19:10   ` Peter Stephenson
2014-01-19 21:35     ` Bart Schaefer
2014-01-19 22:13       ` Simon Ruderich
2014-01-20  0:02         ` Bart Schaefer [this message]
2014-01-20  1:10           ` Bart Schaefer
2014-01-20  1:44             ` Bart Schaefer
2014-01-20  3:20             ` Bart Schaefer
2014-02-24 14:38             ` Oliver Kiddle
2014-02-24 15:38               ` Bart Schaefer

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=140119160238.ZM5850@torch.brasslantern.com \
    --to=schaefer@brasslantern.com \
    --cc=zsh-workers@zsh.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.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

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).