unicorn/qemu/include
Philippe Mathieu-Daudé 24c56c65a3
qemu/compiler: Define QEMU_NONSTRING
GCC 8 introduced the -Wstringop-truncation checker to detect truncation by
the strncat and strncpy functions (closely related to -Wstringop-overflow,
which detect buffer overflow by string-modifying functions declared in
<string.h>).

In tandem of -Wstringop-truncation, the "nonstring" attribute was added:

The nonstring variable attribute specifies that an object or member
declaration with type array of char, signed char, or unsigned char,
or pointer to such a type is intended to store character arrays that
do not necessarily contain a terminating NUL. This is useful in detecting
uses of such arrays or pointers with functions that expect NUL-terminated
strings, and to avoid warnings when such an array or pointer is used as
an argument to a bounded string manipulation function such as strncpy.

From the GCC manual: https://gcc.gnu.org/onlinedocs/gcc/Common-Variable-Attributes.html#index-nonstring-variable-attribute

Add the QEMU_NONSTRING macro which checks if the compiler supports this
attribute.

Backports commit 1daff2f8193496b0e5e0ab56dc48c570c81f804e from qemu
2019-01-22 15:06:09 -05:00
..
crypto Drop unused crypto source files 2018-02-17 15:23:57 -05:00
exec tcg: Add TCG_CALL_NO_RETURN 2019-01-05 06:35:21 -05:00
fpu softfloat: add float{32,64}_is_zero_or_normal 2018-12-19 10:31:10 -05:00
hw Use cpu_create(type) instead of cpu_init(cpu_model) 2018-03-20 14:20:30 -04:00
qapi qapi: Rewrite string-input-visitor's integer and list parsing 2018-12-18 04:57:25 -05:00
qemu qemu/compiler: Define QEMU_NONSTRING 2019-01-22 15:06:09 -05:00
qom move ObjectClass to typedefs.h 2018-12-11 20:37:04 -05:00
sysemu tcg: add options for enabling MTTCG 2018-03-02 09:25:01 -05:00
config.h import 2015-08-21 15:04:50 +08:00
elf.h include/elf: Update elf.h to commit f71a8eaffba3271cf7cdad95572f6996f7523a5b 2018-03-11 15:34:35 -04:00
glib_compat.h Use cpu_create(type) instead of cpu_init(cpu_model) 2018-03-20 14:20:30 -04:00
qemu-common.h tcg: Add EXCP_ATOMIC 2018-02-27 11:57:58 -05:00