fix deadloop w/o return