9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: "Russ Cox" <rsc@swtch.com>
To: "Fans of the OS Plan 9 from Bell Labs" <9fans@cse.psu.edu>
Subject: Re: [9fans] News doesn't get saved in acme Dump
Date: Thu,  1 Feb 2007 22:16:04 -0500	[thread overview]
Message-ID: <ee9e417a0702011916s26f62d7dt42031a10bc08aea9@mail.gmail.com> (raw)
In-Reply-To: <7871fcf50702011909v6b2db61ah4252e229118f3818@mail.gmail.com>

> > Don't fake it -- fix News.  You have the source.
>
> Right.  So… when I try to implement the write-to-ctl in News, what is
> the meaning of the numbers sent?  Reading through
> /acme/mail/src/mail.c and /acme/mail/src/win.c is somewhat less than
> edifying.

/acme/mail/src/mail.c:
	winsetdump(wbox, "/acme/mail", cmd);

/acme/mail/src/win.c:
void
winsetdump(Window *w, char *dir, char *cmd)
{
	if(dir != nil)
		ctlprint(w->ctl, "dumpdir %s\n", dir);
	if(cmd != nil)
		ctlprint(w->ctl, "dump %s\n", cmd);
}

So if you open the ctl file and then do

  fprint(ctl, "dumpdir /news/window/title\n");
  fprint(ctl, "dump News whatever args you use\n");

then you're done.  There are no numbers to send.

Russ


      reply	other threads:[~2007-02-02  3:16 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-02-02  0:48 Joel Salomon
2007-02-02  1:07 ` Russ Cox
2007-02-02  2:36   ` Joel Salomon
2007-02-02  2:46     ` Russ Cox
2007-02-02  3:05       ` Skip Tavakkolian
2007-02-02 14:12         ` cummij
2007-02-02  3:09       ` Joel Salomon
2007-02-02  3:16         ` Russ Cox [this message]

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=ee9e417a0702011916s26f62d7dt42031a10bc08aea9@mail.gmail.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).