terminate task on exception