First check the filedescriptor before marking the device alive

Signed-off-by: Philip Luyckx <philip.luyckx@gmail.com>