natm_pcb.c (92745) | natm_pcb.c (109623) |
---|---|
1/* $FreeBSD: head/sys/netnatm/natm_pcb.c 92745 2002-03-20 02:39:27Z alfred $ */ | 1/* $FreeBSD: head/sys/netnatm/natm_pcb.c 109623 2003-01-21 08:56:16Z alfred $ */ |
2/* $NetBSD: natm_pcb.c,v 1.4 1996/11/09 03:26:27 chuck Exp $ */ 3 4/* 5 * 6 * Copyright (c) 1996 Charles D. Cranor and Washington University. 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without --- 51 unchanged lines hidden (view full) --- 61int wait; 62 63{ 64 struct natmpcb *npcb; 65 66 MALLOC(npcb, struct natmpcb *, sizeof(*npcb), M_PCB, wait | M_ZERO); 67 68#ifdef DIAGNOSTIC | 2/* $NetBSD: natm_pcb.c,v 1.4 1996/11/09 03:26:27 chuck Exp $ */ 3 4/* 5 * 6 * Copyright (c) 1996 Charles D. Cranor and Washington University. 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without --- 51 unchanged lines hidden (view full) --- 61int wait; 62 63{ 64 struct natmpcb *npcb; 65 66 MALLOC(npcb, struct natmpcb *, sizeof(*npcb), M_PCB, wait | M_ZERO); 67 68#ifdef DIAGNOSTIC |
69 if (wait == M_WAITOK && npcb == NULL) panic("npcb_alloc: malloc didn't wait"); | 69 if (wait == 0 && npcb == NULL) panic("npcb_alloc: malloc didn't wait"); |
70#endif 71 72 if (npcb) 73 npcb->npcb_flags = NPCB_FREE; 74 75 return(npcb); 76} 77 --- 114 unchanged lines hidden --- | 70#endif 71 72 if (npcb) 73 npcb->npcb_flags = NPCB_FREE; 74 75 return(npcb); 76} 77 --- 114 unchanged lines hidden --- |