]> git.ipfire.org Git - thirdparty/gnutls.git/commitdiff
guile: Always provide 'scm_gc_malloc_pointerless'.
authorLudovic Courtès <ludo@gnu.org>
Fri, 7 Jun 2019 08:11:12 +0000 (10:11 +0200)
committerLudovic Courtès <ludo@gnu.org>
Fri, 7 Jun 2019 08:19:22 +0000 (10:19 +0200)
* guile/src/core.c (scm_gc_malloc_pointerless)
[!HAVE_SCM_GC_MALLOC_POINTERLESS]: New macro.
(make_session_record_port): Remove #ifdef HAVE_SCM_GC_MALLOC_POINTERLESS.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
guile/src/core.c

index 546d63a1e32477a3ae9b37a9f654cbcbf7a960c0..3187792e92321475ed2961304e9b0b26f5827bde 100644 (file)
@@ -1,5 +1,5 @@
 /* GnuTLS --- Guile bindings for GnuTLS.
-   Copyright (C) 2007-2014, 2016 Free Software Foundation, Inc.
+   Copyright (C) 2007-2014, 2016, 2019 Free Software Foundation, Inc.
 
    GnuTLS is free software; you can redistribute it and/or
    modify it under the terms of the GNU Lesser General Public
 #include "utils.h"
 \f
 
+#ifndef HAVE_SCM_GC_MALLOC_POINTERLESS
+# define scm_gc_malloc_pointerless scm_gc_malloc
+#endif
+
 
 /* SMOB and enums type definitions.  */
 #include "enum-map.i.c"
@@ -958,12 +962,8 @@ make_session_record_port (SCM session)
   const unsigned long mode_bits = SCM_OPN | SCM_RDNG | SCM_WRTNG;
 
   c_port_buf = (unsigned char *)
-#ifdef HAVE_SCM_GC_MALLOC_POINTERLESS
-    scm_gc_malloc_pointerless
-#else
-    scm_gc_malloc
-#endif
-    (SCM_GNUTLS_SESSION_RECORD_PORT_BUFFER_SIZE, session_record_port_gc_hint);
+    scm_gc_malloc_pointerless (SCM_GNUTLS_SESSION_RECORD_PORT_BUFFER_SIZE,
+                              session_record_port_gc_hint);
 
   /* Create a new port.  */
   port = scm_new_port_table_entry (session_record_port_type);