Fix #3716
Fix cmdmod.py daemon error introduced by 77087955