mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2025-09-22 06:11:32 +02:00
BUG/MEDIUM: log: ensure that unique_id is properly initialized
Last memory poisonning patch immediately made this issue appear. The unique_id field is released but not properly initialized. The feature was introduced very recently, no backport is needed.
This commit is contained in:
parent
6e0644339f
commit
bd83314ee9
@ -1204,6 +1204,7 @@ static struct session *peer_session_create(struct peer *peer, struct peer_sessio
|
|||||||
s->srv_error = default_srv_error;
|
s->srv_error = default_srv_error;
|
||||||
|
|
||||||
s->uniq_id = 0;
|
s->uniq_id = 0;
|
||||||
|
s->unique_id = NULL;
|
||||||
|
|
||||||
txn = &s->txn;
|
txn = &s->txn;
|
||||||
/* Those variables will be checked and freed if non-NULL in
|
/* Those variables will be checked and freed if non-NULL in
|
||||||
|
@ -97,6 +97,7 @@ int session_accept(struct listener *l, int cfd, struct sockaddr_storage *addr)
|
|||||||
LIST_ADDQ(&sessions, &s->list);
|
LIST_ADDQ(&sessions, &s->list);
|
||||||
LIST_INIT(&s->back_refs);
|
LIST_INIT(&s->back_refs);
|
||||||
|
|
||||||
|
s->unique_id = NULL;
|
||||||
s->term_trace = 0;
|
s->term_trace = 0;
|
||||||
s->si[0].addr.from = *addr;
|
s->si[0].addr.from = *addr;
|
||||||
s->logs.accept_date = date; /* user-visible date for logging */
|
s->logs.accept_date = date; /* user-visible date for logging */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user