01_noslop.patch (508B)
1 diff --git a/expat/lib/xmlparse.c b/expat/lib/xmlparse.c 2 --- a/expat/lib/xmlparse.c 3 +++ b/expat/lib/xmlparse.c 4 @@ -269,7 +269,9 @@ typedef struct { 5 #define INIT_DATA_BUF_SIZE 1024 6 #define INIT_ATTS_SIZE 16 7 #define INIT_ATTS_VERSION 0xFFFFFFFF 8 -#define INIT_BLOCK_SIZE 1024 9 +/* BEGIN MOZILLA CHANGE (Avoid slop in poolGrow() allocations) */ 10 +#define INIT_BLOCK_SIZE ((int)(1024 - (offsetof(BLOCK, s) / sizeof(XML_Char)))) 11 +/* END MOZILLA CHANGE */ 12 #define INIT_BUFFER_SIZE 1024 13 14 #define EXPAND_SPARE 24