rtcwake: give its wakelock a uniq id

The worry here is that if we have multiple cron jobs running at the same
time, the first one to exit will remove the lock. (I could be wrong on
this.)

Signed-off-by: Willow Barraco <contact@willowbarraco.fr>
This commit is contained in:
Peter John Hartman
2023-02-24 07:21:29 -06:00
committed by Willow Barraco
parent 6213d1dacd
commit 611d4b2f44

View File

@@ -8,11 +8,11 @@
. sxmo_common.sh
# We can have multiple cronjobs at the same time
sxmo_wakelock.sh lock executing_cronjob infinite
sxmo_wakelock.sh lock executing_cronjob_$$ infinite
sxmo_wakelock.sh unlock waiting_cronjob
finish() {
sxmo_wakelock.sh unlock executing_cronjob
sxmo_wakelock.sh unlock executing_cronjob_$$
exit 0
}