From nobody Sat May 30 18:34:26 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=quarantine dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1778864848; cv=none; d=zohomail.com; s=zohoarc; b=AgMuUMs2/vbDcC9I5ebC+oRgHsfAd7Pp8JuFHwra8Fz8nkxscJ8ojP1/SAEBxdzjbUZ0bZNQZ2pXOib0rwEWIJBa24xLDesjkG/X/QyayQNr0EZz27r4WoD2FsK5o4McZf65FIUW6QyURsJh8pCjr4L72MT8dTdBShYF0WIR0Jc= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1778864848; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=P2hDDNOLZ8fIQ2P5wFDLgOPn1vOmAZUZ9hniCmQSeo4=; b=USIvNjJJ87Bdf3i6ChpuOl2rvFyybXXNQdNFDNzV0gHgSPSMH8myMM2M+5e/zMoCoQaYeBPHUa2J95qzreomEgrksqT/NwLnVGm5wZkiIgZWurI3dnrghXMjnVsXy5WDs4bxAm6xH/3wdeOK9FIWYhfw3fDg5I00rNot3C482ts= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=quarantine dis=none) Return-Path: Received: from lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1778864848735283.26547531937854; Fri, 15 May 2026 10:07:28 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1wNw0R-0000d6-Jh; Fri, 15 May 2026 13:07:23 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1wNw0J-0000ZM-5g for qemu-devel@nongnu.org; Fri, 15 May 2026 13:07:16 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1wNw0F-0000wA-21 for qemu-devel@nongnu.org; Fri, 15 May 2026 13:07:14 -0400 Received: from mx-prod-mc-08.mail-002.prod.us-west-2.aws.redhat.com (ec2-35-165-154-97.us-west-2.compute.amazonaws.com [35.165.154.97]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-182-CSRvCnInP16cX_Y33ctqnA-1; Fri, 15 May 2026 13:07:05 -0400 Received: from mx-prod-int-05.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-05.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.17]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-08.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 28D351800372; Fri, 15 May 2026 17:07:04 +0000 (UTC) Received: from corto.redhat.com (unknown [10.44.32.196]) by mx-prod-int-05.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id 9E5551956053; Fri, 15 May 2026 17:07:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1778864826; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=P2hDDNOLZ8fIQ2P5wFDLgOPn1vOmAZUZ9hniCmQSeo4=; b=QLtCzUiDC8Cy72D8Yk9ucGWqGzolSoL78bRUE5/AcUojqRW7TC+gEaBJw6i7ntOJbBBcHt 6Zad3BPKNercvQ9B2xJIkculJ9GcZCXIYztV5QT6ebWm8XevhNv4ZskGHnOYLpy+jl6vLV i0FvNEvYPBA8d1/37eCeX633/fNqyJo= X-MC-Unique: CSRvCnInP16cX_Y33ctqnA-1 X-Mimecast-MFC-AGG-ID: CSRvCnInP16cX_Y33ctqnA_1778864824 From: =?UTF-8?q?C=C3=A9dric=20Le=20Goater?= To: qemu-devel@nongnu.org Cc: Fabiano Rosas , Laurent Vivier , Paolo Bonzini , =?UTF-8?q?C=C3=A9dric=20Le=20Goater?= Subject: [PATCH] tests/qtest: Fix const qualifier build errors Date: Fri, 15 May 2026 19:06:58 +0200 Message-ID: <20260515170658.187252-1-clg@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Scanned-By: MIMEDefang 3.0 on 10.30.177.17 Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists1p.gnu.org; Received-SPF: pass client-ip=170.10.133.124; envelope-from=clg@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -24 X-Spam_score: -2.5 X-Spam_bar: -- X-Spam_report: (-2.5 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.445, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: qemu development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1778864850505158500 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 : ../tests/qtest/libqtest.c: In function =E2=80=98qtest_verbose=E2=80=99: ../tests/qtest/libqtest.c:2175:15: error: assignment discards =E2=80=98cons= t=E2=80=99 qualifier from pointer target type [-Werror=3Ddiscarded-qualifie= rs] 2175 | found =3D strstr(log, domain); Fix this by changing the type of the variable that store the result to 'const char *'. [1] https://sourceware.org/git/?p=3Dglibc.git;a=3Dcommit;h=3Dcd748a63ab1a7a= e846175c532a3daab341c62690 Fixes: f606321be88c ("tests/qtest: Individual verbose switches") Signed-off-by: C=C3=A9dric Le Goater Reviewed-by: Pierrick Bouvier --- tests/qtest/libqtest.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/qtest/libqtest.c b/tests/qtest/libqtest.c index bf9284b9a131..b1e06ea364ec 100644 --- a/tests/qtest/libqtest.c +++ b/tests/qtest/libqtest.c @@ -2146,7 +2146,7 @@ bool mkimg(const char *file, const char *fmt, unsigne= d size_mb) bool qtest_verbose(const char *domain) { const char *log =3D getenv("QTEST_LOG"); - char *found; + const char *found; =20 assert(domain); =20 --=20 2.54.0