mirror of
https://github.com/lakinduakash/linux-wifi-hotspot.git
synced 2024-11-24 21:20:12 +00:00
Merge pull request #320 from simonbru/fix-nm-cleanup
Fix clean-up of unmanaged devices in NetworkManager.conf
This commit is contained in:
commit
59564a79ff
@ -509,7 +509,7 @@ networkmanager_add_unmanaged() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
mutex_lock
|
mutex_lock
|
||||||
UNMANAGED=$(grep -m1 -Eo '^unmanaged-devices=[[:alnum:]:;,-]*' /etc/NetworkManager/NetworkManager.conf)
|
UNMANAGED=$(grep -m1 -Eo '^unmanaged-devices=[[:alnum:]:;,?*~=-]*' /etc/NetworkManager/NetworkManager.conf)
|
||||||
|
|
||||||
WAS_EMPTY=0
|
WAS_EMPTY=0
|
||||||
[[ -z "$UNMANAGED" ]] && WAS_EMPTY=1
|
[[ -z "$UNMANAGED" ]] && WAS_EMPTY=1
|
||||||
@ -566,7 +566,7 @@ networkmanager_rm_unmanaged() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
mutex_lock
|
mutex_lock
|
||||||
UNMANAGED=$(grep -m1 -Eo '^unmanaged-devices=[[:alnum:]:;,-]*' /etc/NetworkManager/NetworkManager.conf | sed 's/unmanaged-devices=//' | tr ';,' ' ')
|
UNMANAGED=$(grep -m1 -Eo '^unmanaged-devices=[[:alnum:]:;,?*~=-]*' /etc/NetworkManager/NetworkManager.conf | sed 's/unmanaged-devices=//' | tr ';,' ' ')
|
||||||
|
|
||||||
if [[ -z "$UNMANAGED" ]]; then
|
if [[ -z "$UNMANAGED" ]]; then
|
||||||
mutex_unlock
|
mutex_unlock
|
||||||
|
Loading…
Reference in New Issue
Block a user