Fixed some bugs around aborting