mirror of
https://github.com/zebrajr/postgres.git
synced 2025-12-07 12:20:31 +01:00
Fix header's size of structs defines in ispell.
This commit is contained in:
parent
a441035198
commit
13ad48eb8a
|
|
@ -461,9 +461,9 @@ mkSPNode(IspellDict * Conf, int low, int high, int level)
|
|||
if (!nchar)
|
||||
return NULL;
|
||||
|
||||
rs = (SPNode *) malloc(SPNHRDSZ + nchar * sizeof(SPNodeData));
|
||||
rs = (SPNode *) malloc(SPNHDRSZ + nchar * sizeof(SPNodeData));
|
||||
MEMOUT(rs);
|
||||
memset(rs, 0, SPNHRDSZ + nchar * sizeof(SPNodeData));
|
||||
memset(rs, 0, SPNHDRSZ + nchar * sizeof(SPNodeData));
|
||||
rs->length = nchar;
|
||||
data = rs->data;
|
||||
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ typedef struct SPNode
|
|||
SPNodeData data[1];
|
||||
} SPNode;
|
||||
|
||||
#define SPNHRDSZ (sizeof(uint32))
|
||||
#define SPNHDRSZ (offsetof(SPNode,data))
|
||||
|
||||
|
||||
typedef struct spell_struct
|
||||
|
|
@ -88,7 +88,7 @@ typedef struct AffixNode
|
|||
AffixNodeData data[1];
|
||||
} AffixNode;
|
||||
|
||||
#define ANHRDSZ (sizeof(uint32))
|
||||
#define ANHRDSZ (offsetof(AffixNode, data))
|
||||
|
||||
typedef struct
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user