[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
xstriconveh: Improve GCC 11 allocation-deallocation checking
From: |
Bruno Haible |
Subject: |
xstriconveh: Improve GCC 11 allocation-deallocation checking |
Date: |
Sat, 07 Aug 2021 23:12:35 +0200 |
User-agent: |
KMail/5.1.3 (Linux/4.4.0-210-generic; KDE/5.18.0; x86_64; ; ) |
2021-08-07 Bruno Haible <bruno@clisp.org>
xstriconveh: Improve GCC 11 allocation-deallocation checking.
* lib/xstriconveh.h: Include <stdlib.h> instead of <stddef.h>.
(xstr_cd_iconveh, xstr_iconveh): Declare that deallocation must happen
through 'free'.
diff --git a/lib/xstriconveh.h b/lib/xstriconveh.h
index 63d530e..e381dd1 100644
--- a/lib/xstriconveh.h
+++ b/lib/xstriconveh.h
@@ -18,7 +18,7 @@
#ifndef _XSTRICONVEH_H
#define _XSTRICONVEH_H
-#include <stddef.h>
+#include <stdlib.h>
/* Get the 'enum iconv_ilseq_handler' and iconveh_t types, and the
iconveh_open, iconveh_close declarations. */
@@ -68,7 +68,8 @@ extern int
extern char *
xstr_cd_iconveh (const char *src,
const iconveh_t *cd,
- enum iconv_ilseq_handler handler);
+ enum iconv_ilseq_handler handler)
+ _GL_ATTRIBUTE_MALLOC _GL_ATTRIBUTE_DEALLOC_FREE;
#endif
@@ -104,7 +105,8 @@ extern int
extern char *
xstr_iconveh (const char *src,
const char *from_codeset, const char *to_codeset,
- enum iconv_ilseq_handler handler);
+ enum iconv_ilseq_handler handler)
+ _GL_ATTRIBUTE_MALLOC _GL_ATTRIBUTE_DEALLOC_FREE;
#ifdef __cplusplus
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- xstriconveh: Improve GCC 11 allocation-deallocation checking,
Bruno Haible <=