improve dead handling