MCPcopy Create free account
hub / github.com/OSGeo/PROJ / pj_clear_initcache

Function pj_clear_initcache

src/initcache.cpp:74–101  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

72/************************************************************************/
73
74void pj_clear_initcache() {
75 if (cache_alloc > 0) {
76 int i;
77
78 pj_acquire_lock();
79
80 for (i = 0; i < cache_count; i++) {
81 paralist *n, *t = cache_paralist[i];
82
83 free(cache_key[i]);
84
85 /* free parameter list elements */
86 for (; t != nullptr; t = n) {
87 n = t->next;
88 free(t);
89 }
90 }
91
92 free(cache_key);
93 free(cache_paralist);
94 cache_count = 0;
95 cache_alloc = 0;
96 cache_key = nullptr;
97 cache_paralist = nullptr;
98
99 pj_release_lock();
100 }
101}
102
103/************************************************************************/
104/* pj_search_initcache() */

Callers 1

proj_cleanupFunction · 0.85

Calls 2

pj_acquire_lockFunction · 0.85
pj_release_lockFunction · 0.85

Tested by

no test coverage detected