Fix reboot that happend if --no-reboot was used