systemd: Fix busctl crash on aarch64 when setting output table format
authorAlin Popa <alin.popa@bmw.de>
Fri, 14 Feb 2020 08:33:43 +0000 (09:33 +0100)
committerŁukasz Stelmach <l.stelmach@samsung.com>
Mon, 12 Feb 2024 15:37:49 +0000 (16:37 +0100)
commit57074abfc9f38b44a13ca9645b81a861644c0839
tree59fa3483f40e18c258a3fd0cd6d2c04bd42fbe0c
parenteb275918d90facb0a59c202a85fd6401f23c0b21
systemd: Fix busctl crash on aarch64 when setting output table format

The enum used for column names is integer type while table_set_display() is parsing
arguments on size_t alignment which may result in assert in table_set_display() if
the size between types missmatch. This patch cast the enums to size_t.
It also fixes all other occurences for table_set_display() and
table_set_sort().

Change-Id: Ie225491ae3f9752183d6ea7993d02ef450ed6ab6
src/analyze/analyze-security.c
src/analyze/analyze.c
src/busctl/busctl.c
src/network/networkctl.c