From nobody Sun Feb 8 17:22:10 2026 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=1636623014; cv=none; d=zohomail.com; s=zohoarc; b=FO2iA29avtOclh9LsrVwuLS41u653b86GyT3KPM/HLi6gc3a+0G4iZFck6GT5XT3brnq8LOg1rs67P5QoSfx5mCxZ93C3BmMrgHveH9SSXA/dL15EMdJAhRP6R3rrfe2PF42o8EzYp6X1iEI9cX6y4QdpKvmqq0FmYouYmBHoy8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1636623014; 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=ZS7Uv1CnetCoLPTz9saLeHL/wHHdwG46f6B405vOZf8=; b=TFNQ8nl/q7BO/kOrf62+PCIQIRIwDjFNXnySxDcQnBewC0k3IoC9pdjJ4l33ODvQQgyFBaheQaxwqYAlskCKbXs6YdRUO2by9DeBUH8YcF/xc592dckL+kH76AwIJ28fWoHgJhEPyGy9YugDtM1Es7zipQvN9SDSvcL0Zk9vVEs= 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 163662301423595.4045145147079; Thu, 11 Nov 2021 01:30:14 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-466-ujBq-RytNt-eOQJxBvfyHQ-1; Thu, 11 Nov 2021 04:30:09 -0500 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id E63AA1006AA6; Thu, 11 Nov 2021 09:30:04 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id C6AA367853; Thu, 11 Nov 2021 09:30:04 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 819BE4EA30; Thu, 11 Nov 2021 09:30:04 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 1AB9SVvW029395 for ; Thu, 11 Nov 2021 04:28:31 -0500 Received: by smtp.corp.redhat.com (Postfix) id 97CEE67848; Thu, 11 Nov 2021 09:28:31 +0000 (UTC) Received: from maggie.redhat.com (unknown [10.43.2.64]) by smtp.corp.redhat.com (Postfix) with ESMTP id 0CDD667841 for ; Thu, 11 Nov 2021 09:28:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1636623013; 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=ZS7Uv1CnetCoLPTz9saLeHL/wHHdwG46f6B405vOZf8=; b=ZB0AJqnLCmuF2IUOcavqdkP2X6H534v+TbFzrnttlSvBsgjbgOUKmh8OM1tVcAekngRc3b P8vNkn5AMDpAmhQ96aXToBjK/WwasxM+7/CjED7J/X6tqyUHhW/ihKhKQGXa1Sa1lt3efi 6uNn4uKWO2FJlD9IQDxHMyEemxT/Bc0= X-MC-Unique: ujBq-RytNt-eOQJxBvfyHQ-1 From: Michal Privoznik To: libvir-list@redhat.com Subject: [PATCH 5/5] Use virSecretObjEndAPI() more Date: Thu, 11 Nov 2021 10:28:21 +0100 Message-Id: <03c1e91ad3f97dac40c1b317ee2e3ea34a575d44.1636622879.git.mprivozn@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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: 1636623015103100001 Content-Type: text/plain; charset="utf-8" Instead of explicit virObjectUnlock(obj) + virObjectUnref(obj) combo the virSecretObjEndAPI() can be used. Signed-off-by: Michal Privoznik --- src/conf/virsecretobj.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/conf/virsecretobj.c b/src/conf/virsecretobj.c index bdd5e4a6f7..212cfe103c 100644 --- a/src/conf/virsecretobj.c +++ b/src/conf/virsecretobj.c @@ -301,8 +301,7 @@ virSecretObjListRemove(virSecretObjList *secrets, virObjectRWLockWrite(secrets); virObjectLock(obj); virHashRemoveEntry(secrets->objs, uuidstr); - virObjectUnlock(obj); - virObjectUnref(obj); + virSecretObjEndAPI(&obj); virObjectRWUnlock(secrets); } =20 --=20 2.32.0