tests/qtest: fix discarded const qualifier warning

Modern compilers warn that the result of strstr() may discard
const qualifiers when assigned to a non-const pointer.

Make 'found' a const char * to fix the warning.

Signed-off-by: Matthew Penney <matt@matthewpenney.net>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Tested-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Tested-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@oss.qualcomm.com>
Signed-off-by: Fabiano Rosas <farosas@suse.de>
This commit is contained in:
Matthew Penney
2026-05-14 19:19:18 +00:00
committed by Fabiano Rosas
parent ac6721b88d
commit e68da5b7a2

View File

@@ -2146,7 +2146,7 @@ bool mkimg(const char *file, const char *fmt, unsigned size_mb)
bool qtest_verbose(const char *domain)
{
const char *log = getenv("QTEST_LOG");
char *found;
const char *found;
assert(domain);