# HG changeset patch # User Jason Rumney # Date 1057503300 0 # Node ID ff38ea4b40ed6b1a99ec85edd323efcccf28fb7f # Parent e4e794926085116f7ed4b85a837401e7a17c09b9 (struct ablock): Only include padding when there is some. diff -r e4e794926085 -r ff38ea4b40ed src/alloc.c --- a/src/alloc.c Sun Jul 06 14:54:30 2003 +0000 +++ b/src/alloc.c Sun Jul 06 14:55:00 2003 +0000 @@ -645,7 +645,7 @@ /* BLOCK_ALIGN has to be a power of 2. */ #define BLOCK_ALIGN (1 << 10) #define BLOCK_BYTES \ - (BLOCK_ALIGN - sizeof (struct aligned_block *) - ABLOCKS_PADDING) + (BLOCK_ALIGN - sizeof (struct alinged_block *) - ABLOCKS_PADDING) /* Internal data structures and constants. */ @@ -676,7 +676,9 @@ struct ablocks *abase; /* The padding of all but the last ablock is unused. The padding of the last ablock in an ablocks is not allocated. */ +#if ABLOCKS_PADDING char padding[ABLOCKS_PADDING]; +#endif }; /* A bunch of consecutive aligned blocks. */