From 8c837c7bf6e096b9d0c055b47df6f4f3be0c8375 Mon Sep 17 00:00:00 2001 From: cinap_lenrek Date: Mon, 16 May 2016 21:49:02 +0200 Subject: [PATCH] exportfs: disallow ORCLOSE in readonly mode (charles forsyth) --- sys/src/cmd/exportfs/exportsrv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/src/cmd/exportfs/exportsrv.c b/sys/src/cmd/exportfs/exportsrv.c index 67b643253..6980648e3 100644 --- a/sys/src/cmd/exportfs/exportsrv.c +++ b/sys/src/cmd/exportfs/exportsrv.c @@ -477,7 +477,7 @@ slave(Fsrpc *f) putsbuf(f); return; case Topen: - if((f->work.mode&3) == OWRITE || (f->work.mode&OTRUNC)){ + if((f->work.mode&3) == OWRITE || (f->work.mode&(OTRUNC|ORCLOSE))){ reply(&f->work, &rhdr, Ereadonly); putsbuf(f); return;