Replace uses of the deprecated std::auto_ptr with OwningPtr.