check_nt: Fixes NULL pointer dereference

Thanks to Vaclav Ovsik for reporting the issue and providing a fix