Commit 702cf4a4 authored by Quentin Khan's avatar Quentin Khan

FAdaptiveSequential: only call P2M if leaf is not empty

parent 8cec32c3
......@@ -128,7 +128,9 @@ public:
// P2M
void source_to_up() {
for(node_t* leaf : _tree.leaves()) {
_kernel.P2M(leaf->getData(), leaf->getParticleContainer());
if(leaf->getParticleContainer()->size() != 0) {
_kernel.P2M(leaf->getData(), leaf->getParticleContainer());
}
}
}
......
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