diff options
author | David Gibson <david@gibson.dropbear.id.au> | 2013-10-28 21:06:53 +1100 |
---|---|---|
committer | David Gibson <david@gibson.dropbear.id.au> | 2013-10-28 21:06:53 +1100 |
commit | 17625371eeea2fa7257361163c52d336a1a98ebc (patch) | |
tree | 9d6ebe9b93acaa2b962d2a6993b4e3b00ce0c708 /util.h | |
parent | 79eebb23dbf1f6eeff1789cd0d6f1c1fe620a487 (diff) | |
download | device-tree-compiler-17625371eeea2fa7257361163c52d336a1a98ebc.tar.gz |
Use stdbool more widely
We already use the C99 bool type from stdbool.h in a few places. However
there are many other places we represent boolean values as plain ints.
This patch changes that.
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'util.h')
-rw-r--r-- | util.h | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -2,6 +2,7 @@ #define _UTIL_H #include <stdarg.h> +#include <stdbool.h> #include <getopt.h> /* @@ -68,7 +69,7 @@ extern char *join_path(const char *path, const char *name); * @param len The string length including terminator * @return 1 if a valid printable string, 0 if not */ -int util_is_printable_string(const void *data, int len); +bool util_is_printable_string(const void *data, int len); /* * Parse an escaped character starting at index i in string s. The resulting |