Skip to content

Commit

Permalink
Fix use-after-move in CITKPFIsolationSumProducer
Browse files Browse the repository at this point in the history
While the code worked with PluginFactory returning raw pointer, it
leads to segfault when it returns unique_ptr.
  • Loading branch information
makortel committed Jun 5, 2019
1 parent f152238 commit 278f8d5
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -96,11 +96,11 @@ namespace citk {
<< "Isolation type: " << isotype << " is not available in the "
<< "list of allowed isolations!.";
}
_isolation_types[thetype->second].emplace_back(std::move(theisolator));
const std::string dash("-");
std::string pname = isotype+dash+coneName+dash+theisolator->additionalCode();
_product_names[thetype->second].emplace_back(pname);
produces<edm::ValueMap<float> >(pname);
_isolation_types[thetype->second].emplace_back(std::move(theisolator));
}
}

Expand Down

0 comments on commit 278f8d5

Please sign in to comment.