Gentoo Archives: gentoo-commits

From: Matt Turner <mattst88@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-fs/nfs-utils/files/
Date: Mon, 02 Sep 2019 07:08:49
Message-Id: 1567408093.998148dd775a5c629266fcd1c93837ac8ee3541d.mattst88@gentoo
1 commit: 998148dd775a5c629266fcd1c93837ac8ee3541d
2 Author: Matt Turner <mattst88 <AT> gentoo <DOT> org>
3 AuthorDate: Mon Sep 2 05:50:16 2019 +0000
4 Commit: Matt Turner <mattst88 <AT> gentoo <DOT> org>
5 CommitDate: Mon Sep 2 07:08:13 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=998148dd
7
8 net-fs/nfs-utils: Don't unexport directories on restart
9
10 Originally added in 2007 (see commit a0fefa89daef "Remove some bashisms
11 and support baselayout-2 restart option." in the historical repo), = vs
12 != looks like an obvious typo. But, with RC_CMD, we don't need the extra
13 restarting variable.
14
15 Closes: https://bugs.gentoo.org/675644
16 Signed-off-by: Matt Turner <mattst88 <AT> gentoo.org>
17
18 net-fs/nfs-utils/files/nfs.initd | 8 +-------
19 1 file changed, 1 insertion(+), 7 deletions(-)
20
21 diff --git a/net-fs/nfs-utils/files/nfs.initd b/net-fs/nfs-utils/files/nfs.initd
22 index 4b572fc2e5e..bf599021c9a 100644
23 --- a/net-fs/nfs-utils/files/nfs.initd
24 +++ b/net-fs/nfs-utils/files/nfs.initd
25 @@ -4,10 +4,6 @@
26
27 extra_started_commands="reload"
28
29 -# This variable is used for controlling whether or not to run exportfs -ua;
30 -# see stop() for more information
31 -restarting=no
32 -
33 # The binary locations
34 exportfs=/usr/sbin/exportfs
35 mountd=/usr/sbin/rpc.mountd
36 @@ -131,7 +127,7 @@ stop() {
37 # then "exportfs -r" will reread the xtab, and all the current
38 # clients will be able to resume NFS activity, *without* needing
39 # to umount/(re)mount the filesystem.
40 - if [ "${restarting}" = no -o "${RC_CMD}" = "restart" ] ; then
41 + if [ "${RC_CMD}" != "restart" ] ; then
42 ebegin "Unexporting NFS directories"
43 # Exportfs likes to hang if networking isn't working.
44 # If that's the case, then try to kill it so the
45 @@ -155,8 +151,6 @@ reload() {
46 }
47
48 restart() {
49 - # See long comment in stop() regarding "restarting" and exportfs -ua
50 - restarting=yes
51 svc_stop
52 svc_start
53 }