9front - general discussion about 9front
 help / color / mirror / Atom feed
* [9front] question about httpd
@ 2022-08-02 16:51 sahu
  2022-08-02 16:56 ` Jacob Moody
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: sahu @ 2022-08-02 16:51 UTC (permalink / raw)
  To: 9front

Hello, 

I have looked at the code, and have a question about the redirectinit() function in /sys/src/cmd/ip/httpd/redirect.c:

void
redirectinit(void)
{
	static Biobuf *b = nil;
	static Qid qid;
	char *file, *line, *s, *host, *field[3];
	static char pfx[] = "http://";

	file = "/sys/lib/httpd.rewrite";
	if(b != nil){
		if(	(Bfildes(b), &qid) == 0)
			return;
		Bterm(b);
	}
...
}

In which cases could b be nil? And since it appears more often in the function, what do "B" (Biobuf, Bfildes, Bterm, ...) and "Q" (Qid) stand for?

Many thanks in advance and best regards, 
sahu

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2022-08-02 19:56 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-08-02 16:51 [9front] question about httpd sahu
2022-08-02 16:56 ` Jacob Moody
2022-08-02 17:12 ` ori
2022-08-02 17:13 ` Kurt H Maier
2022-08-02 17:45   ` Jacob Moody
2022-08-02 18:41     ` ori
2022-08-02 19:34       ` sirjofri
2022-08-02 19:44         ` Jacob Moody
2022-08-02 19:53           ` sahu

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