fix unwarranted error+abort bug