option-parser: Make bools boolean

Graphics / Wayland / Weston - Daniel Stone [collabora.com] - 28 November 2019 19:24 EST

When option-parser is confronted with a boolean option, have it write a bool rather than treating the value as a pointer to an int32.

(lib)weston already heavily uses bool types internally, so this has the nice side effect of eliminating quite a few local variables which only existed as integer shadows of internal boolean variables.

dd8219b3 option-parser: Make bools boolean
clients/confine.c | 4 +-
clients/editor.c | 6 +--
clients/eventdemo.c | 18 ++++-----
clients/nested.c | 2 +-
clients/subsurfaces.c | 4 +-
clients/terminal.c | 4 +-
compositor/main.c | 85 +++++++++++++-----------------------------
shared/option-parser.c | 4 +-
tools/zunitc/src/zunitc_impl.c | 10 ++---
9 files changed, 51 insertions(+), 86 deletions(-)

Upstream: cgit.freedesktop.org


  • Share