Kratos: Infinite recursive function

Created on 6 Nov 2017  路  6Comments  路  Source: KratosMultiphysics/Kratos

Load and save functions in `multipoint_constraint_data.hpp" are calling themselves making it a infinite recursion loop. This will crash.

virtual void save(Serializer &rSerializer) const
{
    KRATOS_SERIALIZE_SAVE_BASE_CLASS(rSerializer, MpcData);
}

virtual void load(Serializer &rSerializer)
{
    KRATOS_SERIALIZE_LOAD_BASE_CLASS(rSerializer, MpcData);
}
Bug Error

Most helpful comment

Sorry for bad code. It probably is a leftover from copy-paste operation.

@loumalouomega this random crashing is fixed in #972

@roigcarlo @pooyan-dadvand the serializer of Kratos does not have a method for std::map / std::unordered_map . Untill such a utility is available (boost serializer is an option here) I am commenting out the save and load functions of this class.

All 6 comments

In fact, in my experience, the MPC crashes randomly in the tests

Well I haven't test it to be honest, I am just reporting win errors (with a little bit more info). Anyway issue was not for you, I misplaced it sorry

I think I have report this in my code review....

Sorry for bad code. It probably is a leftover from copy-paste operation.

@loumalouomega this random crashing is fixed in #972

@roigcarlo @pooyan-dadvand the serializer of Kratos does not have a method for std::map / std::unordered_map . Untill such a utility is available (boost serializer is an option here) I am commenting out the save and load functions of this class.

On the second thought I implemented a custom save and load functions for the MpcData class. I am opening a pull request for review.

Closed via #977

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ipouplana picture ipouplana  路  7Comments

KlausBSautter picture KlausBSautter  路  6Comments

armingeiser picture armingeiser  路  6Comments

josep-m-carbonell picture josep-m-carbonell  路  4Comments

jcotela picture jcotela  路  4Comments