Put 0 in parens to silence an Xcode warning.
authorWayne Davison <wayne@opencoder.net>
Sun, 31 Jan 2021 17:28:34 +0000 (09:28 -0800)
committerWayne Davison <wayne@opencoder.net>
Sun, 31 Jan 2021 17:28:34 +0000 (09:28 -0800)
lib/pool_alloc.c

index f6c6faf6344fb6c4b94812728c4175204cf4dd9a..a1a7245f6f59c6e2d4d6e0be4a1bbe2cdecd23c1 100644 (file)
@@ -9,8 +9,7 @@ struct alloc_pool
        size_t                  size;           /* extent size          */
        size_t                  quantum;        /* allocation quantum   */
        struct pool_extent      *extents;       /* top extent is "live" */
-       void                    (*bomb)();      /* function to call if
-                                                * malloc fails         */
+       void                    (*bomb)();      /* called if malloc fails */
        int                     flags;
 
        /* statistical data */
@@ -49,7 +48,7 @@ pool_create(size_t size, size_t quantum, void (*bomb)(const char*, const char*,
 {
        struct alloc_pool *pool;
 
-       if ((MINALIGN & (MINALIGN - 1)) != 0) {
+       if ((MINALIGN & (MINALIGN - 1)) != (0)) {
                if (bomb)
                        (*bomb)("Compiler error: MINALIGN is not a power of 2", __FILE__, __LINE__);
                return NULL;