Skip to content

Commit

Permalink
Using auto-ptr
Browse files Browse the repository at this point in the history
  • Loading branch information
mkirsano committed Oct 10, 2017
1 parent 86c2540 commit 2922d43
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ class Pythia8Hadronizer : public Py8InterfaceBase {

private:

Vincia::VinciaPlugin* vincia;
std::auto_ptr<Vincia::VinciaPlugin> fvincia;

void doSetRandomEngine(CLHEP::HepRandomEngine* v) override { p8SetRandomEngine(v); }
virtual std::vector<std::string> const& doSharedResources() const override { return p8SharedResources; }
Expand Down Expand Up @@ -311,7 +311,7 @@ Pythia8Hadronizer::Pythia8Hadronizer(const edm::ParameterSet &params) :

if( params.exists( "VinciaPlugin" ) ) {
fMasterGen.reset(new Pythia);
vincia = new Vincia::VinciaPlugin(fMasterGen.get());
fvincia.reset(new Vincia::VinciaPlugin(fMasterGen.get()));
}

}
Expand Down Expand Up @@ -439,8 +439,8 @@ bool Pythia8Hadronizer::initializeForInternalPartons()
}

edm::LogInfo("Pythia8Interface") << "Initializing MasterGen";
if( vincia ) {
vincia->init(); status = true;
if( fvincia.get() ) {
fvincia->init(); status = true;
} else {
status = fMasterGen->init();
}
Expand Down

0 comments on commit 2922d43

Please sign in to comment.