Fix after boot thread-safety issue