Add a mechanism to free the internal memory used
commit52bdfa86a94428280dc402a7b49076ef33d79fd1
authorpgen <p.gen.progs@gmail.com>
Sun, 19 Apr 2020 14:56:40 +0000 (19 16:56 +0200)
committerpgen <p.gen.progs@gmail.com>
Sun, 19 Apr 2020 15:50:54 +0000 (19 17:50 +0200)
tree75612f946c9cc2b5ff9c3a5ce612d1cb00ea74e2
parentd8a49f837535085c9868e8599e3fa79f31e7cb9f
Add a mechanism to free the internal memory used

- Add a public ctxopt_free_memory to explicitly clean up the memory used
  by ctxopt. This function must be called AFTER the last call to one of
  the ctxopt functions.
- Add various function to free the internal structures used.
- Add forgotten calls to free in various places.
- Clean up the code to make it easier to add the new mechanism.
- Add and clarify some comments.
ctxopt.c
ctxopt.h