PHCC[1]:
I had commented the #ifdef INVARIANTS checks out to make sure I ran this code in all kernels and forgot to comment the #ifdefs back in before I committed. Spotted by: bmilekic [1] PHCC = Pointy Hat Correction Commit
This commit is contained in:
parent
a824da445b
commit
780911f210
@ -167,7 +167,7 @@ malloc(size, type, flags)
|
||||
#endif
|
||||
register struct malloc_type *ksp = type;
|
||||
|
||||
/* #ifdef INVARIANTS */
|
||||
#ifdef INVARIANTS
|
||||
/*
|
||||
* To make sure that WAITOK or NOWAIT is set, but not more than
|
||||
* one, and check against the API botches that are common.
|
||||
@ -183,7 +183,7 @@ malloc(size, type, flags)
|
||||
once++;
|
||||
}
|
||||
}
|
||||
/* #endif */
|
||||
#endif
|
||||
#if 0
|
||||
if (size == 0)
|
||||
Debugger("zero size malloc");
|
||||
|
@ -614,7 +614,7 @@ mb_alloc(struct mb_lstmngr *mb_list, int how, short type, short persist,
|
||||
struct mb_bucket *bucket;
|
||||
void *m;
|
||||
|
||||
/* #ifdef INVARIANTS */
|
||||
#ifdef INVARIANTS
|
||||
int flags;
|
||||
|
||||
flags = how & (M_WAITOK | M_NOWAIT | M_DONTWAIT | M_TRYWAIT);
|
||||
@ -627,7 +627,7 @@ mb_alloc(struct mb_lstmngr *mb_list, int how, short type, short persist,
|
||||
how = M_TRYWAIT;
|
||||
}
|
||||
}
|
||||
/* #endif */
|
||||
#endif
|
||||
|
||||
m = NULL;
|
||||
if ((persist & MBP_PERSISTENT) != 0) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user