Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/kern In shmrealloc(), add missing condvar initialisation...
details: https://anonhg.NetBSD.org/src/rev/af3c8c721036
branches: trunk
changeset: 329514:af3c8c721036
user: njoly <njoly%NetBSD.org@localhost>
date: Tue May 27 21:00:46 2014 +0000
description:
In shmrealloc(), add missing condvar initialisations for segments
copied from previous location.
diffstat:
sys/kern/sysv_shm.c | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)
diffs (31 lines):
diff -r eb03bc89b66a -r af3c8c721036 sys/kern/sysv_shm.c
--- a/sys/kern/sysv_shm.c Tue May 27 19:04:29 2014 +0000
+++ b/sys/kern/sysv_shm.c Tue May 27 21:00:46 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: sysv_shm.c,v 1.124 2014/02/25 18:30:11 pooka Exp $ */
+/* $NetBSD: sysv_shm.c,v 1.125 2014/05/27 21:00:46 njoly Exp $ */
/*-
* Copyright (c) 1999, 2007 The NetBSD Foundation, Inc.
@@ -61,7 +61,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sysv_shm.c,v 1.124 2014/02/25 18:30:11 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sysv_shm.c,v 1.125 2014/05/27 21:00:46 njoly Exp $");
#define SYSVSHM
@@ -908,9 +908,11 @@
ALIGN(newshmni * sizeof(struct shmid_ds)));
/* Copy all memory to the new area */
- for (i = 0; i < shm_nused; i++)
+ for (i = 0; i < shm_nused; i++) {
+ cv_init(&newshm_cv[i], "shmwait");
(void)memcpy(&newshmsegs[i], &shmsegs[i],
sizeof(newshmsegs[0]));
+ }
/* Mark as free all new segments, if there is any */
for (; i < newshmni; i++) {
Home |
Main Index |
Thread Index |
Old Index