zsh-workers
 help / color / mirror / code / Atom feed
From: KELEMEN Peter <Peter.Kelemen@cern.ch>
To: zsh-workers@sunsite.dk
Subject: [4.2.0] Src/hist.c:lockhistfile() endless loop
Date: Fri, 7 May 2004 12:35:15 +0200	[thread overview]
Message-ID: <20040507103515.GE12559@chihiro.cern.ch> (raw)

[ Please Cc: me since I'm not subscribed.  Thanks. ]

Hello,

  2141              while (link(tmpfile, lockfile) < 0) {
  2142                  if (stat(lockfile, &sb) < 0) {
  2143                      if (errno == ENOENT)
  2144                          continue;

This looks like an endless loop if
 1) link() fails, and
 2) stat() returns -ENOENT.

It was the case for me with $HOME being on OpenAFS and an expired
ticket (link() returned -EACCES).  What guarantees do we have here
to say that link() will eventually succeed?

Peter

-- 
    .+'''+.         .+'''+.         .+'''+.         .+'''+.         .+''
 Kelemen Péter     /       \       /       \     Peter.Kelemen@cern.ch
.+'         `+...+'         `+...+'         `+...+'         `+...+'


             reply	other threads:[~2004-05-07 10:51 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-05-07 10:35 KELEMEN Peter [this message]
2004-05-07 15:41 ` Wayne Davison

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=20040507103515.GE12559@chihiro.cern.ch \
    --to=peter.kelemen@cern.ch \
    --cc=zsh-workers@sunsite.dk \
    /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).