mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Added check to prevent segfaults for unsupported welltypes
This commit is contained in:
parent
947f419ef8
commit
7f3f03f63d
@ -936,7 +936,11 @@ namespace Opm {
|
||||
for(unsigned int i = 0; i < well_container_.size(); i++){
|
||||
auto& well = well_container_[i];
|
||||
std::shared_ptr<StandardWell<TypeTag> > derived = std::dynamic_pointer_cast<StandardWell<TypeTag> >(well);
|
||||
derived->addWellContribution(wellContribs);
|
||||
if (derived) {
|
||||
derived->addWellContribution(wellContribs);
|
||||
} else {
|
||||
OpmLog::warning("Warning only StandardWell is supported by WellContributions for GPU");
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user