Restore calling insert_pv after search is aborted + small clean-up