rpcd-mod-luci: fix reporting network device flags
authorJo-Philipp Wich <jo@mein.io>
Mon, 6 Feb 2023 14:46:49 +0000 (15:46 +0100)
committerJo-Philipp Wich <jo@mein.io>
Tue, 7 Feb 2023 09:09:42 +0000 (10:09 +0100)
commita570e300061fae7250999c35e4e7215940bca82d
tree454fbf311d8babedce1e865fe918d1dca641106d
parent09c270950793104c4faabe3b10901b7cf3a9fea9
rpcd-mod-luci: fix reporting network device flags

Fix reporting of ceertain flag values larger than 255, such as IFF_PROMISC
by explicitly casting the bit test expression to a boolean result since
the implicit integer truncation to uint8_t will turn the `0x100` result of
a set IFF_PROMISC bit into just `0x0`.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
libs/rpcd-mod-luci/src/luci.c