summaryrefslogtreecommitdiffstats
path: root/support/nfs
diff options
context:
space:
mode:
Diffstat (limited to 'support/nfs')
-rw-r--r--support/nfs/nfsexport.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/support/nfs/nfsexport.c b/support/nfs/nfsexport.c
index 0e8b52b..782cc50 100644
--- a/support/nfs/nfsexport.c
+++ b/support/nfs/nfsexport.c
@@ -93,7 +93,7 @@ nfsexport(struct nfsctl_export *exp)
{
struct nfsctl_arg arg;
int fd;
- if ((fd=open("/proc/net/rpc/nfsd.fh/channel", O_RDWR))>= 0) {
+ if ((fd=open("/proc/net/rpc/nfsd.fh/channel", O_WRONLY))>= 0) {
close(fd);
return exp_unexp(exp, 1);
}
@@ -108,7 +108,7 @@ nfsunexport(struct nfsctl_export *exp)
struct nfsctl_arg arg;
int fd;
- if ((fd=open("/proc/net/rpc/nfsd.fh/channel", O_RDWR))>= 0) {
+ if ((fd=open("/proc/net/rpc/nfsd.fh/channel", O_WRONLY))>= 0) {
close(fd);
return exp_unexp(exp, 0);
}