From f3aa221ffd0f7a68790fad71c8d7af00a34cea22 Mon Sep 17 00:00:00 2001 From: Quentin Young Date: Wed, 23 Sep 2020 15:37:48 -0400 Subject: [PATCH] pimd, zebra: explicit cast int netlink val to uint encoding signed int as unsigned is bad practice; since we want to do it here lets at least be explicit about it Signed-off-by: Quentin Young --- pimd/pim_zlookup.c | 3 ++- zebra/zebra_mroute.c | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/pimd/pim_zlookup.c b/pimd/pim_zlookup.c index 05c9af873..72505a699 100644 --- a/pimd/pim_zlookup.c +++ b/pimd/pim_zlookup.c @@ -600,7 +600,8 @@ int pim_zlookup_sg_statistics(struct channel_oil *c_oil) } stream_get(&lastused, s, sizeof(lastused)); - stream_getl(s); + /* signed success value from netlink_talk; currently unused */ + (void)stream_getl(s); c_oil->cc.lastused = lastused; diff --git a/zebra/zebra_mroute.c b/zebra/zebra_mroute.c index 3af805558..ef0f2d892 100644 --- a/zebra/zebra_mroute.c +++ b/zebra/zebra_mroute.c @@ -65,7 +65,7 @@ stream_failure: stream_put_in_addr(s, &mroute.sg.src); stream_put_in_addr(s, &mroute.sg.grp); stream_put(s, &mroute.lastused, sizeof(mroute.lastused)); - stream_putl(s, suc); + stream_putl(s, (uint32_t)suc); stream_putw_at(s, 0, stream_get_endp(s)); zserv_send_message(client, s);