fixed bug - have to write to abort though