mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-04-16 11:01:11 -07:00
Bug on or round line 170. problem is that certain combinations of
parameters to an MV create can cause MFS Init to fall over with an assertion failure. Eg, try extendby == avgsize Copied from Perforce Change: 16412 ServerID: perforce.ravenbrook.com
This commit is contained in:
parent
fdb220e3de
commit
2f5aa5c5bc
1 changed files with 5 additions and 2 deletions
|
|
@ -1,6 +1,6 @@
|
|||
/* impl.c.poolmv: MANUAL VARIABLE POOL
|
||||
*
|
||||
* $HopeName: MMsrc!poolmv.c(trunk.15) $
|
||||
* $HopeName: MMsrc!poolmv.c(trunk.16) $
|
||||
* Copyright (C) 1994, 1995 Harlequin Group, all rights reserved
|
||||
*
|
||||
* **** RESTRICTION: This pool may not allocate from the arena control
|
||||
|
|
@ -37,7 +37,7 @@
|
|||
#include "poolmfs.h"
|
||||
#include "mpscmv.h"
|
||||
|
||||
SRCID(poolmv, "$HopeName: MMsrc!poolmv.c(trunk.15) $");
|
||||
SRCID(poolmv, "$HopeName: MMsrc!poolmv.c(trunk.16) $");
|
||||
|
||||
|
||||
#define BLOCKPOOL(mv) (MFSPool(&(mv)->blockPoolStruct))
|
||||
|
|
@ -166,6 +166,9 @@ static Res MVInit(Pool pool, va_list arg)
|
|||
/* At 100% fragmentation we will need one block descriptor for every other */
|
||||
/* allocated block, or (extendBy/avgSize)/2 descriptors. See note 1. */
|
||||
blockExtendBy = sizeof(MVBlockStruct) * (extendBy/avgSize)/2;
|
||||
if(blockExtendBy < sizeof(MVBlockStruct)) {
|
||||
blockExtendBy = sizeof(MVBlockStruct);
|
||||
}
|
||||
|
||||
res = PoolInit(&mv->blockPoolStruct.poolStruct, space, PoolClassMFS(),
|
||||
blockExtendBy, sizeof(MVBlockStruct));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue