Replace deprecated std::auto_ptr with boost::scoped_ptr

Change-Id: I1ebfb33063d39f64dc59623df0f942501870c4e7