In the future there will be some error paths inside locking. Make cleanup easier by converting the sections to scoped_guard. Link: https://github.com/openwrt/openwrt/pull/23483 Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>