9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: Martin Neubauer <m.ne@gmx.net>
To: Fans of the OS Plan 9 from Bell Labs <9fans@cse.psu.edu>
Subject: Re: [9fans] Page problems
Date: Sat, 29 Sep 2007 17:28:46 +0200	[thread overview]
Message-ID: <20070929152846.GC801@shodan.homeunix.net> (raw)
In-Reply-To: <cbbc1db9416e956d6a9824b9977fc404@quanstro.net>

* erik quanstrom (quanstro@quanstro.net) wrote:
> in order for im to return nil, this test has to be true
>
> 	if((page < 0 || page >= doc->npage) && !doc->fwdonly)
> 		return nil;
>
> i think the question is, why is page out of range and what's it's value?
>
> - erik

That happens at startup with the -i option. Somewhere in main is a call of
initgfx(nil, 0, nil, nil, 0) in that case. This leads to doc->npage being 0
which puts any value of page out of range in this case. Essentially it's
something of a timing issue. Page wants to display an image and looks for it
in the cache. At that point the cache is empty because page gets the data
via the plumber and the event loop hasn't yet started to process plumbing
messages. At least that's as far as I have understood what's going on. And
it probably isn't the cause for Greg's problem (which I couldn't reproduce).

	Martin




  reply	other threads:[~2007-09-29 15:28 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-29 13:37 Gregory Pavelcak
2007-09-29 13:49 ` erik quanstrom
2007-09-29 14:21   ` Martin Neubauer
2007-09-29 14:35     ` Martin Neubauer
2007-09-29 14:37     ` erik quanstrom
2007-09-29 15:28       ` Martin Neubauer [this message]
2007-09-29 15:41         ` erik quanstrom
2007-09-29 16:17           ` Martin Neubauer

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=20070929152846.GC801@shodan.homeunix.net \
    --to=m.ne@gmx.net \
    --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).