Deleted Added
full compact
sysv_msg.c (83366) sysv_msg.c (83765)
1/* $FreeBSD: head/sys/kern/sysv_msg.c 83366 2001-09-12 08:38:13Z julian $ */
1/* $FreeBSD: head/sys/kern/sysv_msg.c 83765 2001-09-21 09:25:17Z mr $ */
2
3/*
4 * Implementation of SVID messages
5 *
6 * Author: Daniel Boulet
7 *
8 * Copyright 1993 Daniel Boulet and RTMX Inc.
9 *

--- 117 unchanged lines hidden (view full) ---

127static struct msg *msghdrs; /* MSGTQL msg headers */
128static struct msqid_ds *msqids; /* MSGMNI msqid_ds struct's */
129
130static void
131msginit()
132{
133 register int i;
134
2
3/*
4 * Implementation of SVID messages
5 *
6 * Author: Daniel Boulet
7 *
8 * Copyright 1993 Daniel Boulet and RTMX Inc.
9 *

--- 117 unchanged lines hidden (view full) ---

127static struct msg *msghdrs; /* MSGTQL msg headers */
128static struct msqid_ds *msqids; /* MSGMNI msqid_ds struct's */
129
130static void
131msginit()
132{
133 register int i;
134
135 TUNABLE_INT_FETCH("kern.ipc.msgseg", &msginfo.msgseg);
136 TUNABLE_INT_FETCH("kern.ipc.msgssz", &msginfo.msgssz);
137 msginfo.msgmax = msginfo.msgseg * msginfo.msgssz;
138 TUNABLE_INT_FETCH("kern.ipc.msgmni", &msginfo.msgmni);
139
135 msgpool = malloc(msginfo.msgmax, M_MSG, M_WAITOK);
136 if (msgpool == NULL)
137 panic("msgpool is NULL");
138 msgmaps = malloc(sizeof(struct msgmap) * msginfo.msgseg, M_MSG, M_WAITOK);
139 if (msgmaps == NULL)
140 panic("msgmaps is NULL");
141 msghdrs = malloc(sizeof(struct msg) * msginfo.msgtql, M_MSG, M_WAITOK);
142 if (msghdrs == NULL)

--- 1106 unchanged lines hidden ---
140 msgpool = malloc(msginfo.msgmax, M_MSG, M_WAITOK);
141 if (msgpool == NULL)
142 panic("msgpool is NULL");
143 msgmaps = malloc(sizeof(struct msgmap) * msginfo.msgseg, M_MSG, M_WAITOK);
144 if (msgmaps == NULL)
145 panic("msgmaps is NULL");
146 msghdrs = malloc(sizeof(struct msg) * msginfo.msgtql, M_MSG, M_WAITOK);
147 if (msghdrs == NULL)

--- 1106 unchanged lines hidden ---