diff options
author | NIIBE Yutaka <[email protected]> | 2025-04-21 02:43:42 +0000 |
---|---|---|
committer | NIIBE Yutaka <[email protected]> | 2025-04-21 02:43:42 +0000 |
commit | 1c58363541fcc331511d067ce388f32298fd8d29 (patch) | |
tree | 444dbec4975981929b2345c6769d1c6a040424a1 | |
parent | Post release updates (diff) | |
download | libgpg-error-1c58363541fcc331511d067ce388f32298fd8d29.tar.gz libgpg-error-1c58363541fcc331511d067ce388f32298fd8d29.zip |
Mark the initializations with __nonstring__ attribute.
* src/b64enc.c (bintoasc): Use GPGRT_ATTR_NONSTRING.
* src/gpg-error.h.in (GPGRT_ATTR_NONSTRING): New.
--
GnuPG-bug-id: 7621
Signed-off-by: NIIBE Yutaka <[email protected]>
Diffstat (limited to '')
-rw-r--r-- | src/b64enc.c | 1 | ||||
-rw-r--r-- | src/gpg-error.h.in | 6 |
2 files changed, 7 insertions, 0 deletions
diff --git a/src/b64enc.c b/src/b64enc.c index 571f4ec..a4edd0c 100644 --- a/src/b64enc.c +++ b/src/b64enc.c @@ -39,6 +39,7 @@ #define B64ENC_USE_PGPCRC 32 /* The base-64 character list */ +GPGRT_ATTR_NONSTRING static unsigned char const bintoasc[64] = ("ABCDEFGHIJKLMNOPQRSTUVWXYZ" "abcdefghijklmnopqrstuvwxyz" "0123456789+/"); diff --git a/src/gpg-error.h.in b/src/gpg-error.h.in index d925ab0..4b4c60f 100644 --- a/src/gpg-error.h.in +++ b/src/gpg-error.h.in @@ -247,6 +247,12 @@ typedef unsigned int gpg_error_t; # define GPGRT_ATTR_MALLOC #endif +#if _GPG_ERR_GCC_VERSION >= 80000 +# define GPGRT_ATTR_NONSTRING __attribute__((__nonstring__)) +#else +# define GPGRT_ATTR_NONSTRING +#endif + /* A macro defined if a GCC style __FUNCTION__ macro is available. */ #undef GPGRT_HAVE_MACRO_FUNCTION #if _GPG_ERR_GCC_VERSION >= 20500 |