Logging library
[Apache Core]


データ構造

struct  piped_log
 The piped logging structure. [詳細]

マクロ定義

#define APLOG_EMERG   0
#define APLOG_ALERT   1
#define APLOG_CRIT   2
#define APLOG_ERR   3
#define APLOG_WARNING   4
#define APLOG_NOTICE   5
#define APLOG_INFO   6
#define APLOG_DEBUG   7
#define APLOG_LEVELMASK   7
#define APLOG_NOERRNO   (APLOG_LEVELMASK + 1)
#define APLOG_TOCLIENT   ((APLOG_LEVELMASK + 1) * 2)
#define APLOG_STARTUP   ((APLOG_LEVELMASK + 1) * 4)
#define DEFAULT_LOGLEVEL   APLOG_WARNING
#define APLOG_MARK   __FILE__,__LINE__
#define ap_piped_log_read_fd(pl)   ((pl)->fds[0])
#define ap_piped_log_write_fd(pl)   ((pl)->fds[1])

型定義

typedef piped_log piped_log

関数

void ap_open_stderr_log (apr_pool_t *p)
apr_status_t ap_replace_stderr_log (apr_pool_t *p, const char *file)
int ap_open_logs (apr_pool_t *pconf, apr_pool_t *plog, apr_pool_t *ptemp, server_rec *s_main)
void ap_log_error (const char *file, int line, int level, apr_status_t status, const server_rec *s, const char *fmt,...) __attribute__((format(printf
void void ap_log_perror (const char *file, int line, int level, apr_status_t status, apr_pool_t *p, const char *fmt,...) __attribute__((format(printf
void void void ap_log_rerror (const char *file, int line, int level, apr_status_t status, const request_rec *r, const char *fmt,...) __attribute__((format(printf
void void void void ap_log_cerror (const char *file, int line, int level, apr_status_t status, const conn_rec *c, const char *fmt,...) __attribute__((format(printf
void void void void void ap_error_log2stderr (server_rec *s)
void ap_log_pid (apr_pool_t *p, const char *fname)
apr_status_t ap_read_pid (apr_pool_t *p, const char *filename, pid_t *mypid)
piped_logap_open_piped_log (apr_pool_t *p, const char *program)
void ap_close_piped_log (piped_log *pl)

変数

int AP_DECLARE_DATA ap_default_loglevel

マクロ定義

#define ap_piped_log_read_fd ( pl   )     ((pl)->fds[0])

A macro to access the read side of the piped log pipe

引数:
pl The piped log structure
戻り値:
The native file descriptor

#define ap_piped_log_write_fd ( pl   )     ((pl)->fds[1])

A macro to access the write side of the piped log pipe

引数:
pl The piped log structure
戻り値:
The native file descriptor


型定義

typedef struct piped_log piped_log

参照:
piped_log


関数

void ap_close_piped_log ( piped_log pl  ) 

Close the piped log and kill the logging process

引数:
pl The piped log structure

void void void void void ap_error_log2stderr ( server_rec s  ) 

Convert stderr to the error log

引数:
s The current server

void void void void ap_log_cerror ( const char *  file,
int  line,
int  level,
apr_status_t  status,
const conn_rec c,
const char *  fmt,
  ... 
)

ap_log_cerror() - log messages which are related to a particular connection. This uses a a printf-like format to log messages to the error_log.

引数:
file The file in which this function is called
line The line number on which this function is called
level The level of this error message
status The status code from the previous command
c The connection which we are logging for
fmt The format string
... The arguments to use to fill out fmt.
覚え書き:
Use APLOG_MARK to fill out file and line

If a request_rec is available, use that with ap_log_rerror() in preference to calling this function.

警告:
It is VERY IMPORTANT that you not include any raw data from the network, such as the request-URI or request header fields, within the format string. Doing so makes the server vulnerable to a denial-of-service attack and other messy behavior. Instead, use a simple format string like "%s", followed by the string containing the untrusted data.

void ap_log_error ( const char *  file,
int  line,
int  level,
apr_status_t  status,
const server_rec s,
const char *  fmt,
  ... 
)

ap_log_error() - log messages which are not related to a particular request or connection. This uses a printf-like format to log messages to the error_log.

引数:
file The file in which this function is called
line The line number on which this function is called
level The level of this error message
status The status code from the previous command
s The server on which we are logging
fmt The format string
... The arguments to use to fill out fmt.
覚え書き:
Use APLOG_MARK to fill out file and line

If a request_rec is available, use that with ap_log_rerror() in preference to calling this function. Otherwise, if a conn_rec is available, use that with ap_log_cerror() in preference to calling this function.

警告:
It is VERY IMPORTANT that you not include any raw data from the network, such as the request-URI or request header fields, within the format string. Doing so makes the server vulnerable to a denial-of-service attack and other messy behavior. Instead, use a simple format string like "%s", followed by the string containing the untrusted data.

void void ap_log_perror ( const char *  file,
int  line,
int  level,
apr_status_t  status,
apr_pool_t p,
const char *  fmt,
  ... 
)

ap_log_perror() - log messages which are not related to a particular request, connection, or virtual server. This uses a printf-like format to log messages to the error_log.

引数:
file The file in which this function is called
line The line number on which this function is called
level The level of this error message
status The status code from the previous command
p The pool which we are logging for
fmt The format string
... The arguments to use to fill out fmt.
覚え書き:
Use APLOG_MARK to fill out file and line
警告:
It is VERY IMPORTANT that you not include any raw data from the network, such as the request-URI or request header fields, within the format string. Doing so makes the server vulnerable to a denial-of-service attack and other messy behavior. Instead, use a simple format string like "%s", followed by the string containing the untrusted data.

void ap_log_pid ( apr_pool_t p,
const char *  fname 
)

Log the current pid of the parent process

引数:
p The pool to use for logging
fname The name of the file to log to

void void void ap_log_rerror ( const char *  file,
int  line,
int  level,
apr_status_t  status,
const request_rec r,
const char *  fmt,
  ... 
)

ap_log_rerror() - log messages which are related to a particular request. This uses a a printf-like format to log messages to the error_log.

引数:
file The file in which this function is called
line The line number on which this function is called
level The level of this error message
status The status code from the previous command
r The request which we are logging for
fmt The format string
... The arguments to use to fill out fmt.
覚え書き:
Use APLOG_MARK to fill out file and line
警告:
It is VERY IMPORTANT that you not include any raw data from the network, such as the request-URI or request header fields, within the format string. Doing so makes the server vulnerable to a denial-of-service attack and other messy behavior. Instead, use a simple format string like "%s", followed by the string containing the untrusted data.

int ap_open_logs ( apr_pool_t pconf,
apr_pool_t plog,
apr_pool_t ptemp,
server_rec s_main 
)

Open the error log and replace stderr with it.

引数:
pconf Not used
plog The pool to allocate the logs from
ptemp Pool used for temporary allocations
s_main The main server
覚え書き:
ap_open_logs isn't expected to be used by modules, it is an internal core function

piped_log* ap_open_piped_log ( apr_pool_t p,
const char *  program 
)

Open the piped log process

引数:
p The pool to allocate out of
program The program to run in the logging process
戻り値:
The piped log structure

void ap_open_stderr_log ( apr_pool_t p  ) 

Set up for logging to stderr.

引数:
p The pool to allocate out of

apr_status_t ap_read_pid ( apr_pool_t p,
const char *  filename,
pid_t *  mypid 
)

Retrieve the pid from a pidfile.

引数:
p The pool to use for logging
filename The name of the file containing the pid
mypid Pointer to pid_t (valid only if return APR_SUCCESS)

apr_status_t ap_replace_stderr_log ( apr_pool_t p,
const char *  file 
)

Replace logging to stderr with logging to the given file.

引数:
p The pool to allocate out of
file Name of the file to log stderr output


Apacheに対してSun Jul 19 22:05:28 2009に生成されました。  doxygen 1.4.7