]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUILD: peers: fix build warning about unused variable
authorWilly Tarreau <w@1wt.eu>
Fri, 15 Jan 2021 16:08:38 +0000 (17:08 +0100)
committerWilly Tarreau <w@1wt.eu>
Fri, 15 Jan 2021 16:08:38 +0000 (17:08 +0100)
Previous commit da2b0844f ("MINOR: peers: Add traces for peer control
messages.") introduced a build warning on some compiler versions after
the removal of variable "peers" in peer_send_msgs() because variable
"s" was used only to assign this one, and variable "si" to assign "s".
Let's remove both to fix the warning. No backport is needed.

src/peers.c

index 624d268eb5c5a0cd905175806f2be24036fe21b9..e5b1e5714159da41bbf300b4c8240d62e377ab4a 100644 (file)
@@ -2171,8 +2171,6 @@ static inline int peer_send_msgs(struct appctx *appctx,
                                  struct peer *peer, struct peers *peers)
 {
        int repl;
-       struct stream_interface *si = appctx->owner;
-       struct stream *s = si_strm(si);
 
        /* Need to request a resync */
        if ((peer->flags & PEER_F_LEARN_ASSIGN) &&