9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: "Russ Cox" <rsc@swtch.com>
To: 9fans@cse.psu.edu
Subject: Re: namec (was Re: [9fans] Strange date/time on some created files)
Date: Wed, 15 Feb 2006 08:32:55 +0000	[thread overview]
Message-ID: <85e2f17ea519dda15fa4679f40459c54@swtch.com> (raw)
In-Reply-To: <b3585582139dc389754f77db2ca27880@vitanuova.com>

> the problem seems to be that attachimage() relies on sysexec()
> giving it a Chan with a currently valid qid.version, but when
> the last component of the path is translated by a mount
> point, namec returns the qid in the mount table's Chan,
> which holds a stale version number, hence the old
> shared text segment incorrectly used.

actually, namec returns an open chan, and when the chan
is opened, the Ropen includes a qid which is dutifully copied
into c->qid.  so if you run your example from, say, ramfs, 
then it just works.

the bug is in fossil, which fails to update fid->qid.vers in an
Ropen response.  most of the time this is harmless, since the qid that is
there was computed for the immediately preceding Rwalk.
only when mount points get involved do walk and open messages
get separated significantly.

the bug is fixed on sources (/sys/src/cmd/fossil/9p.c).
new binary later.

russ



  reply	other threads:[~2006-02-15  8:32 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-02-12 13:58 rog
2006-02-15  8:32 ` Russ Cox [this message]
2006-02-15  6:29 [9fans] Mt. Xinu Bruce Ellis
2006-02-15 13:04 ` namec (was Re: [9fans] Strange date/time on some created files) rog
2006-02-15 13:07   ` rog

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=85e2f17ea519dda15fa4679f40459c54@swtch.com \
    --to=rsc@swtch.com \
    --cc=9fans@cse.psu.edu \
    /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).