From b8460981c96c4289a9c164133ab5d1fab105ce7d Mon Sep 17 00:00:00 2001
From: David Hendriks <davidhendriks93@gmail.com>
Date: Wed, 12 Aug 2020 17:52:21 +0100
Subject: [PATCH] fixing the api bindings

---
 src/binary_c_python_api.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/binary_c_python_api.c b/src/binary_c_python_api.c
index 3f0938d0b..bd2b2f3a7 100644
--- a/src/binary_c_python_api.c
+++ b/src/binary_c_python_api.c
@@ -123,9 +123,9 @@ int run_system(char * argstring,
         TRUE,                       // free_stardata
         FALSE,                      // free_store
         FALSE                       // free_raw_buffer
+        TRUE,                       // free_persistent TODO: check if this is correct here
     );
 
-
     // add flag or logic to free store contents.
     if (store_memaddr == -1)
     {
@@ -190,6 +190,7 @@ int return_arglines(char ** const buffer,
         TRUE,                       // free_stardata
         FALSE,                      // free_store
         FALSE                       // free_raw_buffer
+        TRUE,                       // free_persistent TODO: check if this is correct here
     );
     
     // TODO: check what this does
@@ -239,6 +240,7 @@ int return_help_info(char * argstring,
         TRUE,                       // free_stardata
         FALSE,                      // free_store
         FALSE                       // free_raw_buffer
+        TRUE,                       // free_persistent TODO: check if this is correct here
     );
 
     // Ask rob whether this can be replaced with setting the thing above to true
@@ -287,6 +289,7 @@ int return_help_all_info(char ** const buffer,
         TRUE,                       // free_stardata
         FALSE,                      // free_store
         FALSE                       // free_raw_buffer
+        TRUE,                       // free_persistent TODO: check if this is correct here
     );
 
 
@@ -335,6 +338,7 @@ int return_version_info(char ** const buffer,
         TRUE,                       // free_stardata
         FALSE,                      // free_store
         FALSE                       // free_raw_buffer
+        TRUE,                       // free_persistent TODO: check if this is correct here
     );
 
     binary_c_free_store_contents(store);
@@ -382,6 +386,7 @@ long int return_store(char * argstring,
         TRUE,                       // free_stardata
         FALSE,                      // free_store
         FALSE                       // free_raw_buffer
+        TRUE,                       // free_persistent TODO: check if this is correct here
     );
 
     /* convert the pointer */ 
-- 
GitLab