summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--configure.ac2
-rw-r--r--src/buffer.c2
-rw-r--r--src/data.c2
-rw-r--r--src/emacs-module.c4
-rw-r--r--src/regex-emacs.c2
-rw-r--r--src/search.c2
6 files changed, 7 insertions, 7 deletions
diff --git a/configure.ac b/configure.ac
index b4674e3204b..93463e344ab 100644
--- a/configure.ac
+++ b/configure.ac
@@ -4516,7 +4516,7 @@ AC_CHECK_FUNCS_ONCE([sbrk])
AC_FUNC_FORK
-AC_CHECK_FUNCS(snprintf)
+AC_CHECK_FUNCS(snprintf __lsan_ignore_object)
dnl Check for glib. This differs from other library checks in that
dnl Emacs need not link to glib unless some other library is already
diff --git a/src/buffer.c b/src/buffer.c
index 3456a46be3e..e441499aeb0 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -5087,7 +5087,7 @@ enlarge_buffer_text (struct buffer *b, ptrdiff_t delta)
#else
p = xrealloc (b->text->beg, new_nbytes);
#endif
-#ifdef HAVE_SANITIZER_LSAN_INTERFACE_H
+#ifdef HAVE___LSAN_IGNORE_OBJECT
__lsan_ignore_object (p);
#endif
diff --git a/src/data.c b/src/data.c
index c261e8e90dd..5fff52d24c2 100644
--- a/src/data.c
+++ b/src/data.c
@@ -1788,7 +1788,7 @@ make_blv (struct Lisp_Symbol *sym, bool forwarded,
set_blv_defcell (blv, tem);
set_blv_valcell (blv, tem);
set_blv_found (blv, false);
-#ifdef HAVE_SANITIZER_LSAN_INTERFACE_H
+#ifdef HAVE___LSAN_IGNORE_OBJECT
__lsan_ignore_object (blv);
#endif
return blv;
diff --git a/src/emacs-module.c b/src/emacs-module.c
index 4374bf4b1c4..f57101946b3 100644
--- a/src/emacs-module.c
+++ b/src/emacs-module.c
@@ -1103,7 +1103,7 @@ DEFUN ("module-load", Fmodule_load, Smodule_load, 1, 1, 0,
if (module_assertions)
{
rt = xmalloc (sizeof *rt);
-#ifdef HAVE_SANITIZER_LSAN_INTERFACE_H
+#ifdef HAVE___LSAN_IGNORE_OBJECT
__lsan_ignore_object (rt);
#endif
}
@@ -1426,7 +1426,7 @@ initialize_environment (emacs_env *env, struct emacs_env_private *priv)
if (module_assertions)
{
env = xmalloc (sizeof *env);
-#ifdef HAVE_SANITIZER_LSAN_INTERFACE_H
+#ifdef HAVE___LSAN_IGNORE_OBJECT
__lsan_ignore_object (env);
#endif
}
diff --git a/src/regex-emacs.c b/src/regex-emacs.c
index 5c08c81c0b5..1ecbc74b96c 100644
--- a/src/regex-emacs.c
+++ b/src/regex-emacs.c
@@ -1761,7 +1761,7 @@ regex_compile (re_char *pattern, ptrdiff_t size,
/* Initialize the compile stack. */
compile_stack.stack = xmalloc (INIT_COMPILE_STACK_SIZE
* sizeof *compile_stack.stack);
-#ifdef HAVE_SANITIZER_LSAN_INTERFACE_H
+#ifdef HAVE___LSAN_IGNORE_OBJECT
__lsan_ignore_object (compile_stack.stack);
#endif
compile_stack.size = INIT_COMPILE_STACK_SIZE;
diff --git a/src/search.c b/src/search.c
index ad5d0302932..7b74ff91480 100644
--- a/src/search.c
+++ b/src/search.c
@@ -619,7 +619,7 @@ newline_cache_on_off (struct buffer *buf)
if (base_buf->newline_cache == 0)
{
base_buf->newline_cache = new_region_cache ();
-#ifdef HAVE_SANITIZER_LSAN_INTERFACE_H
+#ifdef HAVE___LSAN_IGNORE_OBJECT
__lsan_ignore_object (base_buf->newline_cache);
#endif
}