From nobody Sun Apr 28 00:31:09 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1676455589; cv=none; d=zohomail.com; s=zohoarc; b=L8JSb3mJKuMhfJNyDoEHbK0RNByFQc/kBhy+Wpw37YreYL9nk2CdmOUdGs24AKH8PwwnyXt1bHmVdGoeqTRyb22WHRPZ6emHowfJzv5fhyMH6kCsagQVOrHsSwj5H+tu0aSwlTpa2akgQO2eZbcGmRLtv1hi3Snf8mJrr6i+GeA= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1676455589; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=PCe75xyPSVlj6coU5KxRThz5rpkcdos/P6BnnXlFPik=; b=fv0BQNp7UltRrBkK7aqG8YvNPfcCJzLxnKNA4dF3IwDR2ZDPPzgyS7L5Jggg+DmGfd8eMO7WhjOUObMylVZZi2gpVtlcAU+3DwExPg5dwMRY/VNR5GroUMItl3etCTrLqWgIz+ps+9qMWx+LmlpUGr8pK9AJLlRL+uPbkcUFvek= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 1676455589774322.1952268444202; Wed, 15 Feb 2023 02:06:29 -0800 (PST) Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-656--h9S5IvLM1C7xYhCpK-ncA-1; Wed, 15 Feb 2023 05:06:23 -0500 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 8CB583806630; Wed, 15 Feb 2023 10:06:20 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com [10.30.29.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 7803F2026D4B; Wed, 15 Feb 2023 10:06:20 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (localhost [IPv6:::1]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 6D3B61946589; Wed, 15 Feb 2023 10:06:20 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 0B3D71946588 for ; Wed, 15 Feb 2023 10:06:19 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id E9DB32166B31; Wed, 15 Feb 2023 10:06:13 +0000 (UTC) Received: from speedmetal.redhat.com (ovpn-208-8.brq.redhat.com [10.40.208.8]) by smtp.corp.redhat.com (Postfix) with ESMTP id 6692B2166B30 for ; Wed, 15 Feb 2023 10:06:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1676455588; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=PCe75xyPSVlj6coU5KxRThz5rpkcdos/P6BnnXlFPik=; b=MOFeWQLBxOwKCGZYauQBSk3fW6B+Zb/8V28RpYZLNP6QXrIllyFrNq7Lga/OQB2+Ed7/L8 efloemIotMe4Ekc1BexiZhmkr5+47L88ghf8xfCRYDdkNdrnIdDr8fSTF/FoSeqa0/d3KG 1WdfZO7Yvm3LgJvnf4DJrZXjoCVTUWE= X-MC-Unique: -h9S5IvLM1C7xYhCpK-ncA-1 X-Original-To: libvir-list@listman.corp.redhat.com From: Peter Krempa To: libvir-list@redhat.com Subject: [PATCH 1/3] rpc: client: Don't check return value of virNetMessageNew Date: Wed, 15 Feb 2023 11:06:09 +0100 Message-Id: <48ef172fa3aa885d1e2843c7a7fe709ebf668dab.1676455529.git.pkrempa@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.6 X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libvir-list-bounces@redhat.com Sender: "libvir-list" X-Scanned-By: MIMEDefang 3.1 on 10.11.54.4 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1676455591189100001 Content-Type: text/plain; charset="utf-8" virNetServerClientDispatchRead checked the return value but it's not necessary any more as it can't return NULL nowadays. Signed-off-by: Peter Krempa Reviewed-by: Daniel P. Berrang=C3=A9 --- src/rpc/virnetserverclient.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/src/rpc/virnetserverclient.c b/src/rpc/virnetserverclient.c index c9a4eb521e..b5c764b1b0 100644 --- a/src/rpc/virnetserverclient.c +++ b/src/rpc/virnetserverclient.c @@ -1257,13 +1257,10 @@ static virNetMessage *virNetServerClientDispatchRea= d(virNetServerClient *client) /* Possibly need to create another receive buffer */ if (client->nrequests < client->nrequests_max) { - if (!(client->rx =3D virNetMessageNew(true))) { - client->wantClose =3D true; - } else { - client->rx->bufferLength =3D VIR_NET_MESSAGE_LEN_MAX; - client->rx->buffer =3D g_new0(char, client->rx->bufferLeng= th); - client->nrequests++; - } + client->rx =3D virNetMessageNew(true); + client->rx->bufferLength =3D VIR_NET_MESSAGE_LEN_MAX; + client->rx->buffer =3D g_new0(char, client->rx->bufferLength); + client->nrequests++; } else if (!client->nrequests_warning) { client->nrequests_warning =3D true; VIR_WARN("Client hit max requests limit %zd. This may result " --=20 2.39.1 From nobody Sun Apr 28 00:31:09 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1676455623; cv=none; d=zohomail.com; s=zohoarc; b=BywSMF3gunJpzkVDBqCc4x5WnP3UFlljfpoi51Fr1VgMuwpsnqkqlqdxdDfwvgo8v8rHegtlOK3aMr0f5rJWuMfuKLn1AkUt53GSCTblSGRQvymBl2iJEWgzpIQv6s2hx5Ha1+CUGYP6xjWZNrqV5P+2bj0ETFrHzLtyhW7Eo3w= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1676455623; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=6WTWveRNQlIXXTy/P0FaoI1+M248O0h/t7n8Yp3wo7M=; b=LQe4g8+N5+SpJXbZmN7xUSkdzVIvsU5ay7fv8k/ts1Ir1CWJ3jquVjjvYzaVt7RLJUtEVYzxK3ji5rEDFv5rYlQKe4pIjmei9UgqSG9+Er3icFxe3Z2HjRrXk4rCXWcMWOK+yYIvmZW7bnoisv214rgVmp/AwIWPK/5+2Y9HHKI= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 1676455623710464.03851759155907; Wed, 15 Feb 2023 02:07:03 -0800 (PST) Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-354-QsUA8PpvPMid90eVAgV5jA-1; Wed, 15 Feb 2023 05:06:30 -0500 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.rdu2.redhat.com [10.11.54.2]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 1D66C85A5B1; Wed, 15 Feb 2023 10:06:27 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com [10.30.29.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 078814010D5F; Wed, 15 Feb 2023 10:06:27 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (localhost [IPv6:::1]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 9483219465A0; Wed, 15 Feb 2023 10:06:26 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 1A5E21946A40 for ; Wed, 15 Feb 2023 10:06:25 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id E967E2166B33; Wed, 15 Feb 2023 10:06:14 +0000 (UTC) Received: from speedmetal.redhat.com (ovpn-208-8.brq.redhat.com [10.40.208.8]) by smtp.corp.redhat.com (Postfix) with ESMTP id 5617A2166B30 for ; Wed, 15 Feb 2023 10:06:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1676455622; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=6WTWveRNQlIXXTy/P0FaoI1+M248O0h/t7n8Yp3wo7M=; b=VaxRCljic7dvGMwsKPM1BgPP9dgbecA+w89/qeWhZZ2QqKYKU7UIBMxfoG1/K4oxpIkal6 YuKD8Nudmhw50CzYTbEIbBElnyYNmVC2FTERmuH2sR1E8nK/N7vbUl9wbDLXl78cQaPNf5 OD6SodBzkz68YWQR+W0gCb0M0dmuWwI= X-MC-Unique: QsUA8PpvPMid90eVAgV5jA-1 X-Original-To: libvir-list@listman.corp.redhat.com From: Peter Krempa To: libvir-list@redhat.com Subject: [PATCH 2/3] rpc: Don't warn about "max_client_requests" in single-threaded daemons Date: Wed, 15 Feb 2023 11:06:10 +0100 Message-Id: <5afa576ed588abea548c5dfc1e1a864e4be1cb94.1676455529.git.pkrempa@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.6 X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libvir-list-bounces@redhat.com Sender: "libvir-list" X-Scanned-By: MIMEDefang 3.1 on 10.11.54.2 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1676455625339100001 Content-Type: text/plain; charset="utf-8" The warning about max_client_requests is hit inside virtlogd every time a VM starts which spams the logs. Emit the warning only when the client request limit is not 1 and add a warning into the daemon config to not configure it too low instead. Fixes: 031878c2364 Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=3D2145188 Signed-off-by: Peter Krempa Reviewed-by: Daniel P. Berrang=C3=A9 --- src/remote/libvirtd.conf.in | 1 + src/rpc/virnetserverclient.c | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/remote/libvirtd.conf.in b/src/remote/libvirtd.conf.in index 80a98b1529..32a680317a 100644 --- a/src/remote/libvirtd.conf.in +++ b/src/remote/libvirtd.conf.in @@ -374,6 +374,7 @@ # connection. To avoid one client monopolizing the server # this should be a small fraction of the global max_workers # parameter. +# Setting this too low may cause keepalive timeouts. #max_client_requests =3D 5 # Same processing controls, but this time for the admin interface. diff --git a/src/rpc/virnetserverclient.c b/src/rpc/virnetserverclient.c index b5c764b1b0..bdb3552c5d 100644 --- a/src/rpc/virnetserverclient.c +++ b/src/rpc/virnetserverclient.c @@ -1261,7 +1261,8 @@ static virNetMessage *virNetServerClientDispatchRead(= virNetServerClient *client) client->rx->bufferLength =3D VIR_NET_MESSAGE_LEN_MAX; client->rx->buffer =3D g_new0(char, client->rx->bufferLength); client->nrequests++; - } else if (!client->nrequests_warning) { + } else if (!client->nrequests_warning && + client->nrequests_max > 1) { client->nrequests_warning =3D true; VIR_WARN("Client hit max requests limit %zd. This may result " "in keep-alive timeouts. Consider tuning the " --=20 2.39.1 From nobody Sun Apr 28 00:31:09 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.129.124 as permitted sender) client-ip=170.10.129.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1676455584; cv=none; d=zohomail.com; s=zohoarc; b=kTeGi/pWpwF50FwKf3zaiyp+y/IW+yVwhl5hKcSml5mKRnlJJeW/Ur1eBxWoKBYr89L1Y+ZvhebmjbySOrY7eRcnocrfQA9eqakkwJ1VKkY6ZJB4INMNAMqAd4k7GSSJ7A4lfoisyGknpy4oFXTk0X8zA7qgWsDO+uWjo2hWCHY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1676455584; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=Rvmxr6kDUhXUu6ONnk6o73FVqMSoeUwUc0/3Fs/IxmU=; b=DrlSI0faS5QSk7vbc52EBifKzQoPyiQPA3WcjXInT7kLcK0ZLDe0zalsn/4ACFttFs44VUZBGN2DhrKmX0IVg4TD3G8rR9EFQ7B+Tk/+v/4fmE+pCI/mCxK1sncXIL1alF6fVoeCkNYkK10qgQ4mtx5Db49f1fgYvhC8uTP/SK0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mx.zohomail.com with SMTPS id 1676455584722378.95771771181376; Wed, 15 Feb 2023 02:06:24 -0800 (PST) Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-519-kPKf_82tOIGVxKJ4R5Qc1Q-1; Wed, 15 Feb 2023 05:06:22 -0500 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 16792380662D; Wed, 15 Feb 2023 10:06:19 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com [10.30.29.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 393D018EC1; Wed, 15 Feb 2023 10:06:17 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (localhost [IPv6:::1]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 14E791946589; Wed, 15 Feb 2023 10:06:17 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 508531946588 for ; Wed, 15 Feb 2023 10:06:16 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id 31A372166B34; Wed, 15 Feb 2023 10:06:16 +0000 (UTC) Received: from speedmetal.redhat.com (ovpn-208-8.brq.redhat.com [10.40.208.8]) by smtp.corp.redhat.com (Postfix) with ESMTP id 6F2DE2166B30 for ; Wed, 15 Feb 2023 10:06:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1676455583; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=Rvmxr6kDUhXUu6ONnk6o73FVqMSoeUwUc0/3Fs/IxmU=; b=KTCzMciBQ93Bl08unOYX9kIXyPnUdaD7VEbbTJj4RBXO0R6TutEakXUEGaF4cUxqC6O+ad hcXEgvIDyF76MFKbgFB7bjmankkw+vsdHbXPgccGIj3iXAVmZj7REgrZNPEYtrIPkT1X+P LQwfzgaI3JfRrEgTXIetRBm7VKe9Li8= X-MC-Unique: kPKf_82tOIGVxKJ4R5Qc1Q-1 X-Original-To: libvir-list@listman.corp.redhat.com From: Peter Krempa To: libvir-list@redhat.com Subject: [PATCH 3/3] virLogCleanerShutdown: Don't call g_regex_unref on NULL regex Date: Wed, 15 Feb 2023 11:06:11 +0100 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.6 X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libvir-list-bounces@redhat.com Sender: "libvir-list" X-Scanned-By: MIMEDefang 3.1 on 10.11.54.5 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1676455585117100001 Content-Type: text/plain; charset="utf-8" Shutdown of virtlogd prints: (process:54742): GLib-CRITICAL **: 11:00:40.873: g_regex_unref: assertion= 'regex !=3D NULL' failed Use g_clear_pointer instead which prevents it in the NULL case. Fixes: 69eeef5dfbf Signed-off-by: Peter Krempa Reviewed-by: Daniel P. Berrang=C3=A9 --- src/logging/log_cleaner.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/logging/log_cleaner.c b/src/logging/log_cleaner.c index bb8f719f1b..38f818f177 100644 --- a/src/logging/log_cleaner.c +++ b/src/logging/log_cleaner.c @@ -264,6 +264,5 @@ virLogCleanerShutdown(virLogHandler *handler) handler->cleanup_log_timer =3D -1; } - g_regex_unref(log_regex); - log_regex =3D NULL; + g_clear_pointer(&log_regex, g_regex_unref); } --=20 2.39.1