mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-08-01 06:57:50 +00:00
kodi: add glob protection when executing sleep scripts
Avoids the following on suspend: Aug 27 19:48:24 LibreELEC Boot[1043]: ### running sleep script 10-addon-sleep.sh (post)... ### Aug 27 19:48:24 LibreELEC Boot[1047]: ### running addon sleep script /storage/.kodi/addons/*/sleep.d/*.power (post)... ### Aug 27 19:48:24 LibreELEC systemd-sleep[936]: sh: can't open '/storage/.kodi/addons/*/sleep.d/*.power' Aug 27 19:48:24 LibreELEC systemd[1]: Started Suspend.
This commit is contained in:
parent
4a241aec59
commit
120c8f6825
6
packages/mediacenter/kodi/sleep.d.serial/10-addon-sleep.sh
Executable file → Normal file
6
packages/mediacenter/kodi/sleep.d.serial/10-addon-sleep.sh
Executable file → Normal file
@ -23,8 +23,10 @@
|
||||
# see https://wiki.archlinux.org/index.php/Power_Management#Hooks_in_.2Fusr.2Flib.2Fsystemd.2Fsystem-sleep
|
||||
|
||||
for script in $HOME/.kodi/addons/*/sleep.d/*.power; do
|
||||
progress "running addon sleep script $script ($@)..."
|
||||
sh $script $@
|
||||
if [ -f $script ]; then
|
||||
progress "running addon sleep script $script ($@)..."
|
||||
sh $script $@
|
||||
fi
|
||||
done
|
||||
|
||||
exit 0
|
Loading…
x
Reference in New Issue
Block a user