~kris/9p

9hist

23f0453b84be7aec13763b5d8e7976af2a5baa01 — David du Colombier 28 years ago 9671685
Plan 9 from Bell Labs 1997-12-02
1 files changed, 2 insertions(+), 0 deletions(-)

M port/alloc.c
M port/alloc.c => port/alloc.c +2 -0
@@ 186,6 186,8 @@ poolalloc(Pool *p, int size)
	Bhdr *q, *t;
	int alloc, ldr, ns, frag;

	if(size < 0 || size >= 1024*1024*1024)	/* for sanity and to avoid overflow */
		return nil;
	size = (size + BHDRSIZE + p->quanta) & ~(p->quanta);

	ilock(&p->l);