You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by br...@hyperreal.org on 1998/05/19 21:19:06 UTC
cvs commit: apache-1.3/src/modules/standard mod_include.c mod_log_agent.c mod_log_referer.c mod_mime_magic.c mod_rewrite.c mod_rewrite.h
brian 98/05/19 12:19:06
Modified: src/modules/standard mod_include.c mod_log_agent.c
mod_log_referer.c mod_mime_magic.c mod_rewrite.c
mod_rewrite.h
Log:
Cleanups for changes to ap_spawn_child call. Removed an inadvertant
space in mod_include. Work still needed in this area:
ap_spawn_child_err_buff needs to be called to set the child_info
structure, rather than just NULL as it is now.
Revision Changes Path
1.88 +1 -1 apache-1.3/src/modules/standard/mod_include.c
Index: mod_include.c
===================================================================
RCS file: /export/home/cvs/apache-1.3/src/modules/standard/mod_include.c,v
retrieving revision 1.87
retrieving revision 1.88
diff -u -r1.87 -r1.88
--- mod_include.c 1998/05/18 20:41:33 1.87
+++ mod_include.c 1998/05/19 19:19:01 1.88
@@ -1,4 +1,4 @@
- /* ====================================================================
+/* ====================================================================
* Copyright (c) 1995-1998 The Apache Group. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
1.24 +1 -1 apache-1.3/src/modules/standard/mod_log_agent.c
Index: mod_log_agent.c
===================================================================
RCS file: /export/home/cvs/apache-1.3/src/modules/standard/mod_log_agent.c,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -r1.23 -r1.24
--- mod_log_agent.c 1998/04/11 12:00:48 1.23
+++ mod_log_agent.c 1998/05/19 19:19:02 1.24
@@ -101,7 +101,7 @@
{NULL}
};
-static int agent_log_child(void *cmd)
+static int agent_log_child(void *cmd, child_info *pinfo)
{
/* Child process code for 'AgentLog "|..."';
* may want a common framework for this, since I expect it will
1.25 +1 -1 apache-1.3/src/modules/standard/mod_log_referer.c
Index: mod_log_referer.c
===================================================================
RCS file: /export/home/cvs/apache-1.3/src/modules/standard/mod_log_referer.c,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -r1.24 -r1.25
--- mod_log_referer.c 1998/04/11 12:00:48 1.24
+++ mod_log_referer.c 1998/05/19 19:19:02 1.25
@@ -116,7 +116,7 @@
{NULL}
};
-static int referer_log_child(void *cmd)
+static int referer_log_child(void *cmd, child_info *pinfo)
{
/* Child process code for 'RefererLog "|..."';
* may want a common framework for this, since I expect it will
1.31 +1 -1 apache-1.3/src/modules/standard/mod_mime_magic.c
Index: mod_mime_magic.c
===================================================================
RCS file: /export/home/cvs/apache-1.3/src/modules/standard/mod_mime_magic.c,v
retrieving revision 1.30
retrieving revision 1.31
diff -u -r1.30 -r1.31
--- mod_mime_magic.c 1998/04/11 12:00:49 1.30
+++ mod_mime_magic.c 1998/05/19 19:19:02 1.31
@@ -2142,7 +2142,7 @@
int method;
};
-static int uncompress_child(void *data)
+static int uncompress_child(void *data, child_info *pinfo)
{
struct uncompress_parms *parm = data;
#if defined(WIN32)
1.104 +2 -2 apache-1.3/src/modules/standard/mod_rewrite.c
Index: mod_rewrite.c
===================================================================
RCS file: /export/home/cvs/apache-1.3/src/modules/standard/mod_rewrite.c,v
retrieving revision 1.103
retrieving revision 1.104
diff -u -r1.103 -r1.104
--- mod_rewrite.c 1998/05/05 14:04:20 1.103
+++ mod_rewrite.c 1998/05/19 19:19:02 1.104
@@ -2887,7 +2887,7 @@
}
/* Child process code for 'RewriteLog "|..."' */
-static int rewritelog_child(void *cmd)
+static int rewritelog_child(void *cmd, child_info *pinfo)
{
int child_pid = 1;
@@ -3163,7 +3163,7 @@
}
/* child process code */
-static int rewritemap_program_child(void *cmd)
+static int rewritemap_program_child(void *cmd, child_info *pinfo)
{
int child_pid = 1;
1.50 +2 -2 apache-1.3/src/modules/standard/mod_rewrite.h
Index: mod_rewrite.h
===================================================================
RCS file: /export/home/cvs/apache-1.3/src/modules/standard/mod_rewrite.h,v
retrieving revision 1.49
retrieving revision 1.50
diff -u -r1.49 -r1.50
--- mod_rewrite.h 1998/03/31 12:53:20 1.49
+++ mod_rewrite.h 1998/05/19 19:19:03 1.50
@@ -424,7 +424,7 @@
/* rewriting logfile support */
static void open_rewritelog(server_rec *s, pool *p);
-static int rewritelog_child(void *cmd);
+static int rewritelog_child(void *cmd, child_info *pinfo);
static void rewritelog(request_rec *r, int level, const char *text, ...)
__attribute__((format(printf,3,4)));
static char *current_logtime(request_rec *r);
@@ -438,7 +438,7 @@
/* program map support */
static void run_rewritemap_programs(server_rec *s, pool *p);
-static int rewritemap_program_child(void *cmd);
+static int rewritemap_program_child(void *cmd, child_info *pinfo);
/* env variable support */
static void expand_variables_inbuffer(request_rec *r, char *buf, int buf_len);
Re: piped logs
Posted by Dean Gaudet <dg...@arctic.org>.
Incidentally, in apache-nspr I changed error_log to a PRFileDesc * ...
which most closely resembles an int. Well it would, if microsoft wasn't
so goddamn lame.
Dean
On Tue, 19 May 1998, Brian Behlendorf wrote:
> At 09:38 PM 5/19/98 -0700, you wrote:
> >You need to bcreate() to create a BUFF and then bpushfd() the descriptor
> >returned from ap_piped_log_write_fd. Also mark it unbuffered. That gives
> >you a BUFF *... not sure if that's the right solution I haven't had a
> >chance to look at Ben's stuff yet.
>
> I'll leave it alone for now, and not consider it a showstopper for 1.3.0.
>
> Brian
>
>
> --=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=--
> pure chewing satisfaction brian@apache.org
> brian@hyperreal.org
>
Re: piped logs
Posted by Brian Behlendorf <br...@hyperreal.org>.
At 09:38 PM 5/19/98 -0700, you wrote:
>You need to bcreate() to create a BUFF and then bpushfd() the descriptor
>returned from ap_piped_log_write_fd. Also mark it unbuffered. That gives
>you a BUFF *... not sure if that's the right solution I haven't had a
>chance to look at Ben's stuff yet.
I'll leave it alone for now, and not consider it a showstopper for 1.3.0.
Brian
--=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=--
pure chewing satisfaction brian@apache.org
brian@hyperreal.org
Re: piped logs
Posted by Dean Gaudet <dg...@arctic.org>.
On Tue, 19 May 1998, Brian Behlendorf wrote:
> When I try and apply the same deal I did for the other modules, I get a
> cast warning of reassignment - and indeed, s->error_log is defined as a
> FILE * whereas ap_piped_log_write_fd returns an int. It looks like
> changing the definition of error_log from a FILE * to an int could be
> problematic, since "stderr" is by C standards a FILE *.
You need to bcreate() to create a BUFF and then bpushfd() the descriptor
returned from ap_piped_log_write_fd. Also mark it unbuffered. That gives
you a BUFF *... not sure if that's the right solution I haven't had a
chance to look at Ben's stuff yet.
Dean
piped logs
Posted by Brian Behlendorf <br...@hyperreal.org>.
At 10:18 PM 5/19/98 +0100, Ben Laurie wrote:
>Oh yeah - BTW, the things that are doing piped logs should really use
>ap_open_piped_log, which will reduce the pain (as well as making them
>better).
Hmm - http_log itself doesn't use ap_open_piped_logs to open the ErrorLog.
Should it?
When I try and apply the same deal I did for the other modules, I get a
cast warning of reassignment - and indeed, s->error_log is defined as a
FILE * whereas ap_piped_log_write_fd returns an int. It looks like
changing the definition of error_log from a FILE * to an int could be
problematic, since "stderr" is by C standards a FILE *.
For now I'm not going to worry about it I guess, but if anyone's inclined...
Brian
--=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=--
pure chewing satisfaction brian@apache.org
brian@hyperreal.org
Re: cvs commit: apache-1.3/src/modules/standard mod_include.c mod_log_agent.c mod_log_referer.c mod_mime_magic.c mod_rewrite.c mod_rewrite.h
Posted by Ben Laurie <be...@algroup.co.uk>.
brian@hyperreal.org wrote:
>
> brian 98/05/19 12:19:06
>
> Modified: src/modules/standard mod_include.c mod_log_agent.c
> mod_log_referer.c mod_mime_magic.c mod_rewrite.c
> mod_rewrite.h
> Log:
> Cleanups for changes to ap_spawn_child call. Removed an inadvertant
> space in mod_include. Work still needed in this area:
> ap_spawn_child_err_buff needs to be called to set the child_info
> structure, rather than just NULL as it is now.
Oh yeah - BTW, the things that are doing piped logs should really use
ap_open_piped_log, which will reduce the pain (as well as making them
better).
Cheers,
Ben.
--
Ben Laurie |Phone: +44 (181) 735 0686| Apache Group member
Freelance Consultant |Fax: +44 (181) 735 0689|http://www.apache.org
and Technical Director|Email: ben@algroup.co.uk |
A.L. Digital Ltd, |Apache-SSL author http://www.apache-ssl.org/
London, England. |"Apache: TDG" http://www.ora.com/catalog/apache