tools/debug-events: make the print_ functions return the printed string

Two advantages here: fewer actual printf() calls making the output
slightly more coherent if there are other things writing to stdout but
also better re-usability since we can now move the print functions to
shared code.

Part-of: <https://gitlab.freedesktop.org/libinput/libinput/-/merge_requests/1156>
This commit is contained in:
Peter Hutterer 2025-03-10 15:26:02 +10:00 committed by Marge Bot
parent 99ceda011c
commit 1dd8a8965c
2 changed files with 344 additions and 299 deletions

View file

@ -49,6 +49,7 @@
#define truefalse(b) ((b) ? "true" : "false")
#define YESNO(b) ((b) ? "YES" : "NO")
#define TRUEFALSE(b) ((b) ? "TRUE" : "FALSE")
#define onoff(b) ((b) ? "on" : "off")
static inline bool
streq(const char *str1, const char *str2)

File diff suppressed because it is too large Load diff