Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/lib/librumpuser Initialize rw->downgrade when allocating a r...



details:   https://anonhg.NetBSD.org/src/rev/e91a88deba52
branches:  trunk
changeset: 786648:e91a88deba52
user:      pooka <pooka%NetBSD.org@localhost>
date:      Sun May 05 12:27:38 2013 +0000

description:
Initialize rw->downgrade when allocating a rwlock.

should/might/etc fix recent test hangs reported by martin & pgoyette

diffstat:

 lib/librumpuser/rumpuser_pth.c |  5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diffs (26 lines):

diff -r 414f7453aaf4 -r e91a88deba52 lib/librumpuser/rumpuser_pth.c
--- a/lib/librumpuser/rumpuser_pth.c    Sun May 05 11:28:34 2013 +0000
+++ b/lib/librumpuser/rumpuser_pth.c    Sun May 05 12:27:38 2013 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: rumpuser_pth.c,v 1.27 2013/05/03 00:23:49 pooka Exp $  */
+/*     $NetBSD: rumpuser_pth.c,v 1.28 2013/05/05 12:27:38 pooka Exp $  */
 
 /*
  * Copyright (c) 2007-2010 Antti Kantee.  All Rights Reserved.
@@ -28,7 +28,7 @@
 #include "rumpuser_port.h"
 
 #if !defined(lint)
-__RCSID("$NetBSD: rumpuser_pth.c,v 1.27 2013/05/03 00:23:49 pooka Exp $");
+__RCSID("$NetBSD: rumpuser_pth.c,v 1.28 2013/05/05 12:27:38 pooka Exp $");
 #endif /* !lint */
 
 #include <sys/queue.h>
@@ -317,6 +317,7 @@
        NOFAIL_ERRNO(pthread_spin_init(&((*rw)->spin),PTHREAD_PROCESS_PRIVATE));
        (*rw)->readers = 0;
        (*rw)->writer = NULL;
+       (*rw)->downgrade = 0;
 }
 
 void



Home | Main Index | Thread Index | Old Index