aboutsummaryrefslogtreecommitdiff
path: root/src/pipeline.cpp
diff options
context:
space:
mode:
authorKristian Evers <kristianevers@gmail.com>2020-11-20 16:37:12 +0100
committerKristian Evers <kristianevers@gmail.com>2020-11-20 16:40:40 +0100
commit046270a85faf20f38d01e02942d197db74bb8542 (patch)
treef95cc5511d3de0d76070553c3a0b04d71f545c0e /src/pipeline.cpp
parent56f0ad70054eea15e9671cd67aafd14bf7c11c74 (diff)
downloadPROJ-046270a85faf20f38d01e02942d197db74bb8542.tar.gz
PROJ-046270a85faf20f38d01e02942d197db74bb8542.zip
Remove old pj_ memory (de)allocation functions
Gone are pj_malloc, pj_calloc, pj_dalloc and pj_dealloc. Their primary function as API memory functions in proj_api.h is no longer there and the other use as a workaround for old errno problems is no longer valid either. Replaced with malloc and free across the codebase.
Diffstat (limited to 'src/pipeline.cpp')
-rw-r--r--src/pipeline.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/pipeline.cpp b/src/pipeline.cpp
index 56a80848..e9d11604 100644
--- a/src/pipeline.cpp
+++ b/src/pipeline.cpp
@@ -294,8 +294,8 @@ static PJ *destructor (PJ *P, int errlev) {
auto pipeline = static_cast<struct Pipeline*>(P->opaque);
- pj_dealloc (pipeline->argv);
- pj_dealloc (pipeline->current_argv);
+ free (pipeline->argv);
+ free (pipeline->current_argv);
delete pipeline;
P->opaque = nullptr;
@@ -321,7 +321,7 @@ static const char *argv_sentinel = "step";
static char **argv_params (paralist *params, size_t argc) {
char **argv;
size_t i = 0;
- argv = static_cast<char**>(pj_calloc (argc, sizeof (char *)));
+ argv = static_cast<char**>(calloc (argc, sizeof (char *)));
if (nullptr==argv)
return nullptr;
for (; params != nullptr; params = params->next)
@@ -461,7 +461,7 @@ PJ *OPERATION(pipeline,0) {
if (nullptr==argv)
return destructor (P, ENOMEM);
- pipeline->current_argv = current_argv = static_cast<char**>(pj_calloc (argc, sizeof (char *)));
+ pipeline->current_argv = current_argv = static_cast<char**>(calloc (argc, sizeof (char *)));
if (nullptr==current_argv)
return destructor (P, ENOMEM);
@@ -679,7 +679,7 @@ static PJ_COORD pop(PJ_COORD point, PJ *P) {
static PJ *setup_pushpop(PJ *P) {
- auto pushpop = static_cast<struct PushPop*>(pj_calloc (1, sizeof(struct PushPop)));
+ auto pushpop = static_cast<struct PushPop*>(calloc (1, sizeof(struct PushPop)));
P->opaque = pushpop;
if (nullptr==P->opaque)
return destructor(P, ENOMEM);