From 2128c648e096e063d556cfd9805a9eed82a48702 Mon Sep 17 00:00:00 2001 From: Maria Matejka Date: Wed, 4 Dec 2024 10:16:42 +0100 Subject: [PATCH] BMP: Tamed a TX buffer warning --- proto/bmp/bmp.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/proto/bmp/bmp.c b/proto/bmp/bmp.c index aefb195d..40bb55f3 100644 --- a/proto/bmp/bmp.c +++ b/proto/bmp/bmp.c @@ -407,7 +407,7 @@ bmp_tx(struct birdsock *sk) { struct bmp_proto *p = sk->data; - struct bmp_tx_buffer *btb = SKIP_BACK(struct bmp_tx_buffer, data, sk->tbuf); + struct bmp_tx_buffer *btb = SKIP_BACK(struct bmp_tx_buffer, data[0], sk->tbuf); bmp_tx_buffer_free(p, btb); sk->tbuf = NULL; @@ -1032,7 +1032,7 @@ bmp_send_termination_msg(struct bmp_proto *p, enum bmp_term_reason reason) bmp_fix_common_hdr(&stream); if (p->sk->tbuf) - bmp_tx_buffer_free(p, SKIP_BACK(struct bmp_tx_buffer, data, p->sk->tbuf)); + bmp_tx_buffer_free(p, SKIP_BACK(struct bmp_tx_buffer, data[0], p->sk->tbuf)); p->sk->tbuf = stream.start; if (sk_send(p->sk, stream.pos - stream.start) < 0) @@ -1335,7 +1335,7 @@ static void bmp_close_socket(struct bmp_proto *p) { if (p->sk && p->sk->tbuf) - bmp_tx_buffer_free(p, SKIP_BACK(struct bmp_tx_buffer, data, p->sk->tbuf)); + bmp_tx_buffer_free(p, SKIP_BACK(struct bmp_tx_buffer, data[0], p->sk->tbuf)); struct bmp_tx_buffer *btb = p->tx_pending; while (btb)