mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2025-01-27 16:23:18 +00:00
MINOR: log: make lf_text use a const char *
lf_text() should use a const char * otherwise it makes it more complex to use data coming from const strings.
This commit is contained in:
parent
93dbc2bc0e
commit
4f65356a22
@ -122,7 +122,7 @@ int get_log_facility(const char *fac);
|
|||||||
*
|
*
|
||||||
* Return the adress of the \0 character, or NULL on error
|
* Return the adress of the \0 character, or NULL on error
|
||||||
*/
|
*/
|
||||||
char *lf_text(char *dst, char *src, size_t size, struct logformat_node *node);
|
char *lf_text(char *dst, const char *src, size_t size, struct logformat_node *node);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Write a IP adress to the log string
|
* Write a IP adress to the log string
|
||||||
|
@ -495,7 +495,7 @@ int get_log_facility(const char *fac)
|
|||||||
*
|
*
|
||||||
* Return the adress of the \0 character, or NULL on error
|
* Return the adress of the \0 character, or NULL on error
|
||||||
*/
|
*/
|
||||||
char *lf_text(char *dst, char *src, size_t size, struct logformat_node *node)
|
char *lf_text(char *dst, const char *src, size_t size, struct logformat_node *node)
|
||||||
{
|
{
|
||||||
int n;
|
int n;
|
||||||
|
|
||||||
@ -820,7 +820,7 @@ int build_logline(struct session *s, char *dst, size_t maxsize, struct list *lis
|
|||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
list_for_each_entry(tmp, list_format, list) {
|
list_for_each_entry(tmp, list_format, list) {
|
||||||
char *src = NULL;
|
const char *src = NULL;
|
||||||
switch (tmp->type) {
|
switch (tmp->type) {
|
||||||
|
|
||||||
case LOG_FMT_SEPARATOR:
|
case LOG_FMT_SEPARATOR:
|
||||||
|
Loading…
Reference in New Issue
Block a user