Added error checking for bad network reads