branch: elpa/sweeprolog
commit 37f83755f658aa36cba1fc017b06b26552a01a22
Author: Eshel Yaron <m...@eshelyaron.com>
Commit: Eshel Yaron <m...@eshelyaron.com>

    PORT: detect older swipl and disable custom GMP alloc functions
---
 sweep.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/sweep.c b/sweep.c
index 188ada6f55..2aa5522081 100644
--- a/sweep.c
+++ b/sweep.c
@@ -426,7 +426,12 @@ sweep_initialize(emacs_env *env, ptrdiff_t nargs, 
emacs_value *args, void *data)
       return NULL;
     }
   }
+
+  if (PL_version_info(PL_VERSION_SYSTEM < 80516))
+    PL_action(PL_GMP_SET_ALLOC_FUNCTIONS, FALSE);
+
   r = PL_initialise(nargs, argv);
+
   for (i = 0; i < nargs; i++) {
     free(argv[i]);
   }

Reply via email to