]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
MFC: r361854
authorRick Macklem <rmacklem@FreeBSD.org>
Sun, 28 Jun 2020 01:29:14 +0000 (01:29 +0000)
committerRick Macklem <rmacklem@FreeBSD.org>
Sun, 28 Jun 2020 01:29:14 +0000 (01:29 +0000)
commit432f475364addd13bdc00fd036efa3c572c9e0bc
tree23e54d7aeadba0f1d92fe5b97ad8338a19486f94
parent97dccbb02e9296b567dbcc634de938b1265e93d2
MFC: r361854
Fix mountd so that it will not lose SIGHUPs that indicate "reload exports".

Without this patch, if a SIGHUP is handled while the process is executing
get_exportlist(), that SIGHUP is essentially ignored because the got_sighup
variable is reset to 0 after get_exportlist().
This results in the exports file(s) not being reloaded until another SIGHUP
signal is sent to mountd.
This patch fixes this by resetting got_sighup to zero before the
get_exportlist() call while SIGHUP is blocked.
It also defines a delay time of 250msec before doing another exports reload
if there are RPC request(s) to process. This prevents repeated exports reloads
from delaying handling of RPC requests significantly.

PR: 246597
usr.sbin/mountd/mountd.c