also reset the deadend flag"