From c27c4204f0d734bc1a889b4405469ac83d568883 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Wed, 2 Mar 2016 21:16:00 +0100 Subject: Cleanup and add missing header inclusions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- src/zand.c | 1 + src/zlsb.c | 3 +-- src/zor.c | 3 +++ src/zsetu.c | 2 ++ src/zsplit.c | 2 +- src/zstr.c | 3 +++ src/zxor.c | 3 +++ 7 files changed, 14 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/zand.c b/src/zand.c index 3156857..950ad8e 100644 --- a/src/zand.c +++ b/src/zand.c @@ -1,6 +1,7 @@ /* See LICENSE file for copyright and license details. */ #include "internals" +#include #include diff --git a/src/zlsb.c b/src/zlsb.c index d63752e..6c0ae6e 100644 --- a/src/zlsb.c +++ b/src/zlsb.c @@ -7,9 +7,8 @@ zlsb(z_t a) { size_t i = 0; zahl_char_t x; - if (zzero(a)) { + if (zzero(a)) return SIZE_MAX; - } for (;; i++) { x = a->chars[i]; if (x) { diff --git a/src/zor.c b/src/zor.c index 0f17f8d..96a4565 100644 --- a/src/zor.c +++ b/src/zor.c @@ -1,6 +1,9 @@ /* See LICENSE file for copyright and license details. */ #include "internals" +#include +#include + void zor(z_t a, z_t b, z_t c) diff --git a/src/zsetu.c b/src/zsetu.c index dd1be17..c3c3510 100644 --- a/src/zsetu.c +++ b/src/zsetu.c @@ -1,6 +1,8 @@ /* See LICENSE file for copyright and license details. */ #include "internals" +#include + #define SIZE_MULTIPLE(fit, in) ((sizeof(fit) + sizeof(in) - 1) / sizeof(in)) diff --git a/src/zsplit.c b/src/zsplit.c index 40b3e54..3e7940b 100644 --- a/src/zsplit.c +++ b/src/zsplit.c @@ -13,7 +13,7 @@ zsplit(z_t high, z_t low, z_t a, size_t delim) return; } - chars = delim >> LB_BITS_PER_CHAR; + chars = FLOOR_BITS_TO_CHARS(delim); if (high == a) { if (a->used < chars) diff --git a/src/zstr.c b/src/zstr.c index a1d4d13..e71b20f 100644 --- a/src/zstr.c +++ b/src/zstr.c @@ -1,6 +1,9 @@ /* See LICENSE file for copyright and license details. */ #include "internals" +#include +#include + #define num libzahl_tmp_str_num #define rem libzahl_tmp_str_rem diff --git a/src/zxor.c b/src/zxor.c index 4c68448..26e5b59 100644 --- a/src/zxor.c +++ b/src/zxor.c @@ -1,6 +1,9 @@ /* See LICENSE file for copyright and license details. */ #include "internals" +#include +#include + void zxor(z_t a, z_t b, z_t c) -- cgit v1.2.3-70-g09d2