Commit f04f3fa8 authored by Jens Kroeger's avatar Jens Kroeger
Browse files

Cluster: fix segfault if charge negative

parent 355d4fa7
Pipeline #2694248 passed with stages
in 20 minutes and 15 seconds
......@@ -51,7 +51,7 @@ std::vector<const Pixel*> Cluster::pixels() const {
const Pixel* Cluster::getSeedPixel() const {
Pixel* seed = nullptr;
double maxcharge = -1;
double maxcharge = -std::numeric_limits<double>::max();
// loop overall pixels and find the one with the largest charge:
for(auto& px : m_pixels) {
auto pxl = dynamic_cast<Pixel*>(px.GetObject());
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment