coin-or / qpOASES

Open-source C++ implementation of the recently proposed online active set strategy
GNU Lesser General Public License v2.1
376 stars 127 forks source link

How to delete QProblem object? #30

Closed svigerske closed 4 years ago

svigerske commented 4 years ago

Issue created by migration from Trac.

Original creator: grimmehesten

Original creation time: 2014-12-15 22:06:17

Assignee: ferreau

Version: 3.0.0

After the last QP problem has been solved how do I delete the QProblem object? What else do I need to delete in order to avoid memory leaks?

svigerske commented 4 years ago

Comment by ferreau created at 2014-12-17 09:58:08

In general, the destructor of the (S)QProblem(B) class will take care of freeing all internal memory. If you allocated the object dynamically (e.g. using new), you need to free it the usual way after its last use.

If that does not answer your question, please be more specific. If you encounter a memory leak when using qpOASES, please send us a code snippet to reproduce the issue such that we can fix it.

svigerske commented 4 years ago

Comment by ferreau created at 2014-12-17 09:58:08

Resolution: fixed