From nobody Mon Feb 9 01:21:58 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 205.139.110.120 as permitted sender) client-ip=205.139.110.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zoho.com: domain of redhat.com designates 205.139.110.120 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=1573650486; cv=none; d=zoho.com; s=zohoarc; b=TtgofxhafrcWC5+K95Zf7HzVTmwrgiFTujy2Zsikp4TmpFdUzvPgmt5GUXXlD+Dy1GzGuzJUF33uw4ONJFYxk4DkHfDrI5GAV6ZldWrzL53Rdkqni3ADuc/ugk3ppQKh29mV/E+vn2dLhRYFkbQ4QMf0GD2YciA0GwOFmyD6WGY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1573650486; 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=LCmUXesRxP7jR19Av8tNRKOCAg4e0YZAmRwG2yzoQT4=; b=GSGnEt60FSiA7/n2dUQ/VeYUDa1Mo1RYnGqEoIxk9I3TXSu+ehEqDrKq63YMpukuy68ZOqAFTziNxXJaSWcsj5t9zVBY0bVY730lrVLzl325N/mSL1YiyYs9iC9WQY+qN57XfWJReqFoK8klWCQNqEmFIyVHcsYMUXleUj3k6cU= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=pass; spf=pass (zoho.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) by mx.zohomail.com with SMTPS id 1573650486174544.9699969617221; Wed, 13 Nov 2019 05:08:06 -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-163-zJUPgbIvMhO8x2yipMgefQ-1; Wed, 13 Nov 2019 08:07:31 -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 F13C8107ACCD; Wed, 13 Nov 2019 13:07:22 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id C4B7C891C; Wed, 13 Nov 2019 13:07:22 +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 7CCEF1832DEA; Wed, 13 Nov 2019 13:07:22 +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 xADD7FTc007071 for ; Wed, 13 Nov 2019 08:07:15 -0500 Received: by smtp.corp.redhat.com (Postfix) id 3235260CCC; Wed, 13 Nov 2019 13:07:15 +0000 (UTC) Received: from angien.redhat.com (unknown [10.43.2.48]) by smtp.corp.redhat.com (Postfix) with ESMTP id AEFD160BE0 for ; Wed, 13 Nov 2019 13:07:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1573650485; 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=LCmUXesRxP7jR19Av8tNRKOCAg4e0YZAmRwG2yzoQT4=; b=fCQndNcfLTzXAWmHqYma0cs5Un/Ix65vgTDIVtB2AvLP3QDp7aF6ExM6xyS23HO+akKU4m +J8wWJ3+Wcs5RiYNHpcz8dp9YTjeO1rrIQdM2kbuhvxjL3XZfYxoWxGLybxPXhRcpHgWKK zTCTrLBbW9A3GPMIuHmZIFFjcufUMl8= From: Peter Krempa To: libvir-list@redhat.com Date: Wed, 13 Nov 2019 14:07:03 +0100 Message-Id: <40c541763391b41e351dddf702016aeb13613f55.1573649216.git.pkrempa@redhat.com> 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 Subject: [libvirt] [PATCH 2/8] util: file: Remove virFileReadLink 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 X-MC-Unique: zJUPgbIvMhO8x2yipMgefQ-1 X-Mimecast-Spam-Score: 0 Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" The function is unused so we can remove it. Signed-off-by: Peter Krempa --- src/libvirt_private.syms | 1 - src/util/virfile.c | 13 ------------- src/util/virfile.h | 3 --- 3 files changed, 17 deletions(-) diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms index 4d0d03c580..c706553e37 100644 --- a/src/libvirt_private.syms +++ b/src/libvirt_private.syms @@ -1978,7 +1978,6 @@ virFileReadBufQuiet; virFileReadHeaderFD; virFileReadHeaderQuiet; virFileReadLimFD; -virFileReadLink; virFileReadValueBitmap; virFileReadValueInt; virFileReadValueScaledInt; diff --git a/src/util/virfile.c b/src/util/virfile.c index ced0ea70b7..b1aeaa5851 100644 --- a/src/util/virfile.c +++ b/src/util/virfile.c @@ -81,7 +81,6 @@ #include "virutil.h" #include "c-ctype.h" -#include "areadlink.h" #define VIR_FROM_THIS VIR_FROM_NONE @@ -1625,18 +1624,6 @@ virFileIsLink(const char *linkpath) return S_ISLNK(st.st_mode) !=3D 0; } -/* - * Read where symlink is pointing to. - * - * Returns 0 on success (@linkpath is a successfully read link), - * -1 with errno set upon error. - */ -int -virFileReadLink(const char *linkpath, char **resultpath) -{ - return (*resultpath =3D areadlink(linkpath)) ? 0 : -1; -} - /* * Finds a requested executable file in the PATH env. e.g.: * "qemu-img" will return "/usr/bin/qemu-img" diff --git a/src/util/virfile.h b/src/util/virfile.h index a570529330..9a8709b52c 100644 --- a/src/util/virfile.h +++ b/src/util/virfile.h @@ -176,9 +176,6 @@ int virFileResolveAllLinks(const char *linkpath, int virFileIsLink(const char *linkpath) ATTRIBUTE_NONNULL(1) G_GNUC_WARN_UNUSED_RESULT; -int virFileReadLink(const char *linkpath, char **resultpath) - ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(2) G_GNUC_WARN_UNUSED_RESULT; - char *virFindFileInPath(const char *file); char *virFileFindResource(const char *filename, --=20 2.23.0 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list