added a simple watch dog