You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
qemu/util
Cédric Le Goater 326e620fc0 Fix const qualifier build errors with recent glibc
A recent change in glibc 2.42.9000 [1] changes the return type of
strstr() and other string functions to be 'const char *' when the
input is a 'const char *'.

This breaks the build in various files with errors such as :

  error: initialization discards 'const' qualifier from pointer target type [-Werror=discarded-qualifiers]
    208 |         char *pidstr = strstr(filename, "%");
        |                        ^~~~~~

Fix this by changing the type of the variables that store the result
of these functions to 'const char *'.

[1] https://sourceware.org/git/?p=glibc.git;a=commit;h=cd748a63ab1a7ae846175c532a3daab341c62690

Signed-off-by: Cédric Le Goater <clg@redhat.com>
Reviewed-by: Laurent Vivier <laurent@vivier.eu>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-ID: <20251209174328.698774-1-clg@redhat.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
1 week ago
..
aio-posix.c aio-posix: add aio_add_sqe() API for user-defined io_uring requests 1 month ago
aio-posix.h aio-posix: add aio_add_sqe() API for user-defined io_uring requests 1 month ago
aio-wait.c aio-wait: avoid AioContext lock in aio_wait_bh_oneshot() 3 years ago
aio-win32.c aio: add errp argument to aio_context_setup() 1 month ago
aiocb.c
async.c block/io_uring: use aio_add_sqe() 1 month ago
atomic64.c osdep: Move memalign-related functions to their own header 4 years ago
base64.c
bitmap.c migration: Use non-atomic ops for clear log bitmap 3 years ago
bitops.c replace TABs with spaces 3 years ago
block-helpers.c block: Adjust check_block_size() signature 1 year ago
block-helpers.h block: Adjust check_block_size() signature 1 year ago
buffer.c
bufferiszero.c util/bufferiszero: Split out host include files 2 years ago
cacheflush.c buildsys: Remove support for 32-bit PPC hosts 2 months ago
chardev_open.c util/char_dev: Add open_cdev() 2 years ago
compatfd.c util: replace pipe()+cloexec with g_unix_open_pipe() 4 years ago
coroutine-sigaltstack.c osdep: set _FORTIFY_SOURCE=2 when optimization is enabled 2 years ago
coroutine-ucontext.c coroutine-ucontext: Save fake stack for pooled coroutine 2 years ago
coroutine-wasm.c util: Add coroutine backend for emscripten 7 months ago
coroutine-windows.c build: move coroutine backend selection to meson 3 years ago
cpuinfo-aarch64.c util/cpuinfo: Make use of elf_aux_info(3) on OpenBSD 1 year ago
cpuinfo-i386.c cpuinfo/i386: Detect GFNI as an AVX extension 3 months ago
cpuinfo-loongarch.c util/loongarch64: Detect LASX vector support 2 years ago
cpuinfo-ppc.c util/cpuinfo: Make use of elf_aux_info(3) on OpenBSD 1 year ago
cpuinfo-riscv.c util/cpuinfo-riscv: Detect Zbs 11 months ago
crc-ccitt.c util: Add CRC16 (CCITT) calculation routines 5 years ago
crc32c.c igb: Implement Rx SCTP CSO 3 years ago
cutils.c util/cutils: Remove unused qemu_get_exec_dir 1 year ago
dbus.c
defer-call.c util/defer-call: move defer_call() to util/ 2 years ago
drm.c
envlist.c envlist: Remove unused envlist_parse 1 year ago
error-report.c Remove glib compatibility code that is not required anymore 2 years ago
error.c error: Kill @error_warn 3 months ago
event.c qemu-thread: Use futex for QemuEvent on Windows 6 months ago
event_notifier-posix.c treewide: use qemu_set_blocking instead of g_unix_set_fd_nonblocking 3 months ago
event_notifier-win32.c Remove qemu-common.h include from most units 4 years ago
fdmon-epoll.c aio-posix: integrate fdmon into glib event loop 1 month ago
fdmon-io_uring.c aio-posix: add aio_add_sqe() API for user-defined io_uring requests 1 month ago
fdmon-poll.c aio-posix: integrate fdmon into glib event loop 1 month ago
fifo8.c fifo8: introduce fifo8_peek() function 1 year ago
filemonitor-inotify.c util/filemonitor-inotify.c: spelling fix: kenel 2 years ago
filemonitor-stub.c
getauxval.c util/cpuinfo: Make use of elf_aux_info(3) on OpenBSD 1 year ago
guest-random.c util/guest-random: Clean up global variable shadowing 2 years ago
hbitmap.c qapi/crypto: Rename QCryptoHashAlgorithm to *Algo, and drop prefix 1 year ago
hexdump.c util/hexdump: fix QEMU_HEXDUMP_LINE_WIDTH logic 1 month ago
host-utils.c host-utils: Implemented signed 256-by-128 division 4 years ago
id.c net: Use id_generate() in the network subsystem, too 5 years ago
int128.c include/qemu/int128: Use Int128 structure for TCI 3 years ago
interval-tree.c util/interval-tree: Check root for null in interval_tree_iter_first 2 years ago
iov.c util/iov: Do not assert offset is in iov 9 months ago
iova-tree.c vhost-iova-tree, svq: Implement GPA->IOVA & partial IOVA->HVA trees 10 months ago
keyval.c qapi: Move include/qapi/qmp/ to include/qobject/ 10 months ago
lockcnt.c qemu-thread: Use futex if available for QemuLockCnt 6 months ago
log.c Fix const qualifier build errors with recent glibc 1 week ago
main-loop.c timers: properly prefix init_clocks() 1 month ago
memalign.c osdep: Move memalign-related functions to their own header 4 years ago
memfd.c physmem: fd-based shared memory 11 months ago
meson.build qemu-thread: Use futex for QemuEvent on Windows 6 months ago
mmap-alloc.c util/mmap-alloc: qemu_fd_getfs() 3 years ago
module.c overall: Remove unnecessary g_strdup_printf() calls 10 months ago
notify.c notify: pass error to notifier with return 2 years ago
nvdimm-utils.c Clean up includes 5 years ago
osdep.c migration: Add direct-io parameter 2 years ago
oslib-posix.c oslib: qemu_clear_cloexec 2 months ago
oslib-win32.c oslib: qemu_clear_cloexec 2 months ago
path.c
qdist.c util: spelling fixes 2 years ago
qemu-co-shared-resource.c util/co-shared-resource: Remove unused co_try_get_from_shres 1 year ago
qemu-co-timeout.c util: add qemu-co-timeout 4 years ago
qemu-config.c qapi: Move include/qapi/qmp/ to include/qobject/ 10 months ago
qemu-coroutine-io.c aio: remove aio_disable_external() API 3 years ago
qemu-coroutine-lock.c atomics: eliminate mb_read/mb_set 3 years ago
qemu-coroutine-sleep.c coroutine: Clean up superfluous inclusion of qemu/coroutine.h 3 years ago
qemu-coroutine.c util/coroutine: fix -Werror=maybe-uninitialized false-positive 1 year ago
qemu-option.c qapi: Move include/qapi/qmp/ to include/qobject/ 10 months ago
qemu-print.c
qemu-progress.c include: move progress API to qemu-progress.h 4 years ago
qemu-sockets.c util/qemu-sockets: Introduce inet socket options controlling TCP keep-alive 7 months ago
qemu-thread-common.h bql: Fix bql_locked status with condvar APIs 1 month ago
qemu-thread-posix.c qemu-thread: Use futex for QemuEvent on Windows 6 months ago
qemu-thread-win32.c qemu-thread: Use futex for QemuEvent on Windows 6 months ago
qemu-timer-common.c semihosting: Implement SYS_ELAPSED and SYS_TICKFREQ 5 years ago
qemu-timer.c timers: properly prefix init_clocks() 1 month ago
qht.c cleanup: Drop pointless return at end of function 8 months ago
qsp.c system/cpus: rename qemu_mutex_lock_iothread() to bql_lock() 2 years ago
qtree.c tcg: use QTree instead of GTree 3 years ago
range.c util/range.c: spelling fix: inbetween 2 years ago
rcu.c rcu: Unify force quiescent state 2 months ago
readline.c util/readline: Add C-u shortcut 2 years ago
reserved-region.c util/reserved-region: Add new ReservedRegion helpers 2 years ago
s390x_pci_mmio.c util: Add functions for s390x mmio read/write 7 months ago
selfmap.c util/selfmap: Use dev_t and ino_t in MapInfo 2 years ago
stats64.c stat64: Add stat64_set() operation 3 years ago
sys_membarrier.c
systemd.c systemd: Also clear LISTEN_FDNAMES during systemd socket activation 3 years ago
thread-context.c qom: Make InterfaceInfo[] uses const 8 months ago
thread-pool.c thread-pool: Implement generic (non-AIO) pool support 10 months ago
throttle.c throttle: use THROTTLE_MAX/ARRAY_SIZE for hard code 2 years ago
timed-average.c license: Simplify GPL-2.0-or-later license descriptions 1 year ago
trace-events aio-posix: add aio_add_sqe() API for user-defined io_uring requests 1 month ago
trace.h
transactions.c transactions: Invoke clean() after everything else 4 years ago
unicode.c
userfaultfd.c util/userfaultfd: Remove unused uffd_poll_events 1 year ago
uuid.c util/uuid: Add UUID_STR_LEN definition 2 years ago
vfio-helpers.c include/system: Move exec/memory.h to system/memory.h 8 months ago
vhost-user-server.c util/vhost-user-server: vu_message_read(): improve error handling 3 months ago
yank.c qapi: Fix dangling references to docs/devel/qapi-code-gen.txt 2 years ago