svn commit: r211830 - head/sys/rpc

Rick Macklem rmacklem at FreeBSD.org
Wed Aug 25 23:23:01 UTC 2010


Author: rmacklem
Date: Wed Aug 25 23:23:00 2010
New Revision: 211830
URL: http://svn.freebsd.org/changeset/base/211830

Log:
  Add mutex locking for the call to replay_prune() in
  replay_setsize(), since replay_prune() expects the
  rc_lock to be held when it is called.
  
  MFC after:	2 weeks

Modified:
  head/sys/rpc/replay.c

Modified: head/sys/rpc/replay.c
==============================================================================
--- head/sys/rpc/replay.c	Wed Aug 25 22:48:18 2010	(r211829)
+++ head/sys/rpc/replay.c	Wed Aug 25 23:23:00 2010	(r211830)
@@ -90,8 +90,10 @@ void
 replay_setsize(struct replay_cache *rc, size_t newmaxsize)
 {
 
+	mtx_lock(&rc->rc_lock);
 	rc->rc_maxsize = newmaxsize;
 	replay_prune(rc);
+	mtx_unlock(&rc->rc_lock);
 }
 
 void


More information about the svn-src-head mailing list