fix hung bug