broadcom-wl: don't inherit lock descriptor in nas process

Add a local hack to prevent the Broadcom WPA authenticator process from
inheriting the lock descriptor 1000 used to prevent concurrent executions
of the init script.

Without this fix, repeated invocations of /etc/init.d/network, e.g. for
obtaining the enabled state, would hang forever.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
This commit is contained in:
Jo-Philipp Wich
2020-05-28 13:03:02 +02:00
parent 8b8fb79cbf
commit a03d6d2fab
2 changed files with 5 additions and 2 deletions

View File

@@ -443,7 +443,10 @@ EOF
txpower=${txpower:-$vif_txpower}
[ -z "$txpower" ] || iwconfig $device txpower ${txpower}dBm
eval "$nas_cmd"
# fd 1000 is an inherited lock file descriptor for preventing concurrent
# init script executions. Close it here to prevent the nas daemon from
# inheriting it further to avoid holding the lock indefinitely.
eval "$nas_cmd 1000>&-"
}