diff options
| author | Even Rouault <even.rouault@spatialys.com> | 2019-08-26 23:21:12 +0200 |
|---|---|---|
| committer | Even Rouault <even.rouault@spatialys.com> | 2019-08-26 23:21:12 +0200 |
| commit | 96ac0f210b6dd3fdb499115d83bc13ff7739cd60 (patch) | |
| tree | 976815754bd15dabb80311f5f6da4a9da0cf88dc /src/malloc.cpp | |
| parent | 10a30bb539be1afb25952b19af8bbe72e1b13b56 (diff) | |
| download | PROJ-96ac0f210b6dd3fdb499115d83bc13ff7739cd60.tar.gz PROJ-96ac0f210b6dd3fdb499115d83bc13ff7739cd60.zip | |
Add a proj_cleanup() function to free global resources, typically at process termination
Diffstat (limited to 'src/malloc.cpp')
| -rw-r--r-- | src/malloc.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/malloc.cpp b/src/malloc.cpp index 817f8f20..393437e3 100644 --- a/src/malloc.cpp +++ b/src/malloc.cpp @@ -255,3 +255,10 @@ PJ *pj_default_destructor (PJ *P, int errlev) { /* Destructor */ delete P; return nullptr; } + +/*****************************************************************************/ +void proj_cleanup() { +/*****************************************************************************/ + pj_clear_initcache(); + pj_deallocate_grids(); +} |
