From nobody Mon Feb 9 10:49:43 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=1638282823; cv=none; d=zohomail.com; s=zohoarc; b=eyiQzX5SmSx0qUhY1PGKFtSZbD4U0f325RRFzl7qI/88VZIn3I7W7R9diS7dpy6xl8BM4EeHkCSHPGJiuK1BaVscfCEGH/OX9ShnxK61i1cPY0wmsIgluUoVZC+Eb5MT+4Bk/QxdZpRG//PMH/WZ2I2LgncIag54ugDB3k+vcPk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1638282823; 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=5BdL6XqU2pIt/kycConbeqt+GEe3jQXPiWS98UdfftY=; b=ZCOEzYo/hQxYoUVfNV5cLIt6WREsnxiXTXHLOkAIHy5qv8rjGeTgxwKKQay0T+EVGmk1mA43h2ClR4PJpmW8fiR8ygH/Qsuca+Gg1ais42RfnUcKulWR1XYt3P6PC3qpJ/u8vwzUuQ503LaI+N7FbzXo+GRrnbyDkuTW87i3+dE= 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 1638282823973339.9084438854371; Tue, 30 Nov 2021 06:33:43 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-178-nImKxAg8OomknbXa0axVzg-1; Tue, 30 Nov 2021 09:33:38 -0500 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 879261014B78; Tue, 30 Nov 2021 14:33:31 +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 69413196E2; Tue, 30 Nov 2021 14:33:31 +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 36F314A70A; Tue, 30 Nov 2021 14:33:31 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 1AUEXOfo022956 for ; Tue, 30 Nov 2021 09:33:24 -0500 Received: by smtp.corp.redhat.com (Postfix) id 8169C6107E; Tue, 30 Nov 2021 14:33:24 +0000 (UTC) Received: from speedmetal.lan (unknown [10.40.208.10]) by smtp.corp.redhat.com (Postfix) with ESMTP id BF31360C0F for ; Tue, 30 Nov 2021 14:33:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1638282823; 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=5BdL6XqU2pIt/kycConbeqt+GEe3jQXPiWS98UdfftY=; b=R8b/djc1RfM6uIX3Z0/crqvYbV9t8CZLiH0kZRIUd0EQ5+nqGrzOJa4h6h3gVbDlyxo2bU XgYcEXWxyja4yfTwqyVvauDHAvtzh8kyHFOHcxzdunIxDSAyUHKgbQF5tjPPgS6xYvxH1Z RnXdM5IXMM8IQvjsBY8c4nnEbXABTkk= X-MC-Unique: nImKxAg8OomknbXa0axVzg-1 From: Peter Krempa To: libvir-list@redhat.com Subject: [PATCH 22/23] util: virhash: Remove 'virHashFree' Date: Tue, 30 Nov 2021 15:32:06 +0100 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 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.84 on 10.5.11.23 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: 1638282824955100001 Content-Type: text/plain; charset="utf-8" The code was converted to stop using this function. Signed-off-by: Peter Krempa Reviewed-by: J=C3=A1n Tomko --- src/libvirt_private.syms | 1 - src/util/virhash.c | 19 ------------------- src/util/virhash.h | 1 - 3 files changed, 21 deletions(-) diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms index b98cb0f66d..dbdc812d0a 100644 --- a/src/libvirt_private.syms +++ b/src/libvirt_private.syms @@ -2372,7 +2372,6 @@ virHashEqual; virHashForEach; virHashForEachSafe; virHashForEachSorted; -virHashFree; virHashGetItems; virHashHasEntry; virHashLookup; diff --git a/src/util/virhash.c b/src/util/virhash.c index cc6053f28d..ce954e86ec 100644 --- a/src/util/virhash.c +++ b/src/util/virhash.c @@ -116,25 +116,6 @@ virHashAtomicDispose(void *obj) } -/** - * virHashFree: - * @table: the hash table - * - * Free the hash @table and its contents. The userdata is - * deallocated with function provided at creation time. - * - * Deprecated: consider using g_hash_table_unref instead - */ -void -virHashFree(GHashTable *table) -{ - if (table =3D=3D NULL) - return; - - g_hash_table_unref(table); -} - - /** * virHashAddEntry: * @table: the hash table diff --git a/src/util/virhash.h b/src/util/virhash.h index 426d835cfc..fcab8454bd 100644 --- a/src/util/virhash.h +++ b/src/util/virhash.h @@ -52,7 +52,6 @@ typedef int (*virHashSearcher) (const void *payload, cons= t char *name, */ GHashTable *virHashNew(virHashDataFree dataFree) G_GNUC_WARN_UNUSED_RESULT; virHashAtomic *virHashAtomicNew(virHashDataFree dataFree); -void virHashFree(GHashTable *table); ssize_t virHashSize(GHashTable *table); /* --=20 2.31.1