mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2025-01-18 11:40:50 +00:00
MINOR: log: make all lf_* sess build helper static
There is no need to expose such functions since they are only involved in the log building process that occurs inside sess_build_logline(). Making functions static and removing their public prototype to ease code maintenance.
This commit is contained in:
parent
3b9096bd36
commit
a1583ec7c7
@ -147,27 +147,6 @@ int get_log_level(const char *lev);
|
|||||||
*/
|
*/
|
||||||
int get_log_facility(const char *fac);
|
int get_log_facility(const char *fac);
|
||||||
|
|
||||||
/*
|
|
||||||
* Write a string in the log string
|
|
||||||
* Take cares of quote options
|
|
||||||
*
|
|
||||||
* Return the address of the \0 character, or NULL on error
|
|
||||||
*/
|
|
||||||
char *lf_text_len(char *dst, const char *src, size_t len, size_t size, const struct logformat_node *node);
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Write a IP address to the log string
|
|
||||||
* +X option write in hexadecimal notation, most significant byte on the left
|
|
||||||
*/
|
|
||||||
char *lf_ip(char *dst, const struct sockaddr *sockaddr, size_t size, const struct logformat_node *node);
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Write a port to the log
|
|
||||||
* +X option write in hexadecimal notation, most significant byte on the left
|
|
||||||
*/
|
|
||||||
char *lf_port(char *dst, const struct sockaddr *sockaddr, size_t size, const struct logformat_node *node);
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Function to handle log header building (exported for sinks)
|
* Function to handle log header building (exported for sinks)
|
||||||
*/
|
*/
|
||||||
|
@ -1905,7 +1905,7 @@ static inline char *_lf_quotetext_len(char *dst, const char *src,
|
|||||||
*
|
*
|
||||||
* Return the address of the \0 character, or NULL on error
|
* Return the address of the \0 character, or NULL on error
|
||||||
*/
|
*/
|
||||||
char *lf_text_len(char *dst, const char *src, size_t len, size_t size, const struct logformat_node *node)
|
static char *lf_text_len(char *dst, const char *src, size_t len, size_t size, const struct logformat_node *node)
|
||||||
{
|
{
|
||||||
if ((node->options & LOG_OPT_QUOTE))
|
if ((node->options & LOG_OPT_QUOTE))
|
||||||
return _lf_quotetext_len(dst, src, len, size, node);
|
return _lf_quotetext_len(dst, src, len, size, node);
|
||||||
@ -1927,7 +1927,7 @@ char *lf_text_len(char *dst, const char *src, size_t len, size_t size, const str
|
|||||||
* Same as lf_text_len() except that it ignores mandatory and quoting options.
|
* Same as lf_text_len() except that it ignores mandatory and quoting options.
|
||||||
* Quoting is only performed when strictly required by the encoding method.
|
* Quoting is only performed when strictly required by the encoding method.
|
||||||
*/
|
*/
|
||||||
char *lf_rawtext_len(char *dst, const char *src, size_t len, size_t size, const struct logformat_node *node)
|
static char *lf_rawtext_len(char *dst, const char *src, size_t len, size_t size, const struct logformat_node *node)
|
||||||
{
|
{
|
||||||
return _lf_text_len(dst, src, len, size, node);
|
return _lf_text_len(dst, src, len, size, node);
|
||||||
}
|
}
|
||||||
@ -1948,7 +1948,7 @@ static inline char *lf_rawtext(char *dst, const char *src, size_t size, const st
|
|||||||
* Write a IP address to the log string
|
* Write a IP address to the log string
|
||||||
* +X option write in hexadecimal notation, most significant byte on the left
|
* +X option write in hexadecimal notation, most significant byte on the left
|
||||||
*/
|
*/
|
||||||
char *lf_ip(char *dst, const struct sockaddr *sockaddr, size_t size, const struct logformat_node *node)
|
static char *lf_ip(char *dst, const struct sockaddr *sockaddr, size_t size, const struct logformat_node *node)
|
||||||
{
|
{
|
||||||
char *ret = dst;
|
char *ret = dst;
|
||||||
int iret;
|
int iret;
|
||||||
@ -2033,7 +2033,7 @@ static inline char *lf_int(char *dst, size_t size, int64_t value,
|
|||||||
* Write a port to the log
|
* Write a port to the log
|
||||||
* +X option write in hexadecimal notation, most significant byte on the left
|
* +X option write in hexadecimal notation, most significant byte on the left
|
||||||
*/
|
*/
|
||||||
char *lf_port(char *dst, const struct sockaddr *sockaddr, size_t size, const struct logformat_node *node)
|
static char *lf_port(char *dst, const struct sockaddr *sockaddr, size_t size, const struct logformat_node *node)
|
||||||
{
|
{
|
||||||
char *ret = dst;
|
char *ret = dst;
|
||||||
int iret;
|
int iret;
|
||||||
|
Loading…
Reference in New Issue
Block a user