Added some error handling routines for Windows