Replace the last auto_ptr by unique_ptr