From nobody Sun Feb 8 14:56:42 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) client-ip=8.43.85.245; envelope-from=devel-bounces@lists.libvirt.org; helo=lists.libvirt.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) smtp.mailfrom=devel-bounces@lists.libvirt.org; dmarc=pass(p=none dis=none) header.from=flant.com ARC-Seal: i=1; a=rsa-sha256; t=1770375873; cv=none; d=zohomail.com; s=zohoarc; b=n+bdMdSkaGG4GaZRlhSJHcVuDSqcBQeXDj1XPPm5wfjQ2up2p+O3EqSyIa//f+qvCwtG0YKtGBGy11fm5zxuGb75qrPEFqFYGuh+dM+9IlaZwfx0tBOAS1xQcmpTZEgL8fohug8xIbc4yIO6lfirCjbAH7y1oNcXCm97w8QFEVM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1770375873; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Owner:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Subject:Subject:To:To:Message-Id:Reply-To; bh=4DBLsAcZoq8gks+RjaMVW6HSeqLsjWQa988b6YJtfic=; b=bB4h48WNzx2Ffcv7cm4GKEKzc+XpRD/3terdGzXPh6JGhxVQKkVhjZbQfN3Oxqxw1BZH06bYkzFfEV06DHNRGRPiKe289d/jE0QNIpuMtYqM1Y9uP0dhrlxRrlxyMYrSYXiPvYXVxYiziHvsT+dkqUCAXV91DYpVEYrW2YdOgt0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) smtp.mailfrom=devel-bounces@lists.libvirt.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.libvirt.org (lists.libvirt.org [8.43.85.245]) by mx.zohomail.com with SMTPS id 1770375873021379.23645174965634; Fri, 6 Feb 2026 03:04:33 -0800 (PST) Received: by lists.libvirt.org (Postfix, from userid 993) id 51C5D41A32; Fri, 6 Feb 2026 06:04:30 -0500 (EST) Received: from [172.19.199.6] (lists.libvirt.org [8.43.85.245]) by lists.libvirt.org (Postfix) with ESMTP id B5DF741AEE; Fri, 6 Feb 2026 06:03:51 -0500 (EST) Received: by lists.libvirt.org (Postfix, from userid 993) id BF70F3F9B4; Fri, 6 Feb 2026 06:03:47 -0500 (EST) Received: from forward103a.mail.yandex.net (forward103a.mail.yandex.net [178.154.239.86]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (3072 bits) server-digest SHA256) (No client certificate requested) by lists.libvirt.org (Postfix) with ESMTPS id 0238F3FA54 for ; Fri, 6 Feb 2026 06:03:45 -0500 (EST) Received: from mail-nwsmtp-smtp-production-main-74.vla.yp-c.yandex.net (mail-nwsmtp-smtp-production-main-74.vla.yp-c.yandex.net [IPv6:2a02:6b8:c1f:5d94:0:640:92d3:0]) by forward103a.mail.yandex.net (Yandex) with ESMTPS id 4D1FC80B4F; Fri, 06 Feb 2026 14:03:43 +0300 (MSK) Received: by mail-nwsmtp-smtp-production-main-74.vla.yp-c.yandex.net (smtp/Yandex) with ESMTPSA id Z3MLx42GSOs0-SAINTuGT; Fri, 06 Feb 2026 14:03:43 +0300 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on lists.libvirt.org X-Spam-Level: X-Spam-Status: No, score=-5.3 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED,RCVD_IN_VALIDITY_RPBL_BLOCKED, RCVD_IN_VALIDITY_SAFE_BLOCKED,SPF_PASS autolearn=unavailable autolearn_force=no version=4.0.1 X-Yandex-Fwd: 1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=flant.com; s=mail; t=1770375823; bh=4DBLsAcZoq8gks+RjaMVW6HSeqLsjWQa988b6YJtfic=; h=Message-Id:Date:In-Reply-To:Cc:Subject:References:To:From; b=FKB8u8cWdrtimow66thYjaw0vG3RXcfw9Y+2n8U8IbeafkpuytKGQbzLTrEBHPZuj BI9rhRt+LlhXkGtxNIzOmPFdgzP6+NBF2UVahNiQTHGsZrvKcVESe+iAfvH06SuVP0 HFN+oMZKFMsYDKy/5nMX2qR9f5xpwk2PO4G1lOh0= Authentication-Results: mail-nwsmtp-smtp-production-main-74.vla.yp-c.yandex.net; dkim=pass header.i=@flant.com From: Dmitry Lopatin To: Peter Krempa Subject: [PATCH v5] virt-aa-helper: Fix unchecked return value Date: Fri, 6 Feb 2026 14:03:32 +0300 Message-Id: <20260206110332.166162-1-dmitry.lopatin@flant.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Message-ID-Hash: E3E7D6BULSQBG3MHKDP3X7QP4EKYQIT4 X-Message-ID-Hash: E3E7D6BULSQBG3MHKDP3X7QP4EKYQIT4 X-MailFrom: dmitry.lopatin@flant.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; header-match-devel.lists.libvirt.org-0; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: devel@lists.libvirt.org, Dmitry Lopatin X-Mailman-Version: 3.3.10 Precedence: list List-Id: Development discussions about the libvirt library & tools Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-ZohoMail-DKIM: pass (identity @flant.com) X-ZM-MESSAGEID: 1770375875394154100 Content-Type: text/plain; charset="utf-8" Add missing return value checks to fix the following issues reported by the static analyzer: - virDriverLoadModule() call when loading the storage driver (line 908) was not checked, while there are examples with return code check throughout the code. Signed-off-by: Dmitry Lopatin --- src/security/virt-aa-helper.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/security/virt-aa-helper.c b/src/security/virt-aa-helper.c index f4ec6b7826..38625f3721 100644 --- a/src/security/virt-aa-helper.c +++ b/src/security/virt-aa-helper.c @@ -892,7 +892,8 @@ get_files(vahControl * ctl) =20 /* load the storage driver so that backing store can be accessed */ #ifdef WITH_STORAGE - virDriverLoadModule("storage", "storageRegister", false); + if (virDriverLoadModule("storage", "storageRegister", false) < 0) + return -1; #endif =20 for (i =3D 0; i < ctl->def->ndisks; i++) { --=20 2.34.1