Fixed crash on empty terminal input.