From nobody Mon Feb 9 12:08:59 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.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 (zohomail.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=1579779907; cv=none; d=zohomail.com; s=zohoarc; b=Q9VMfYUX/HEZF8Z3skOaXPCj8MInDu+wXr9zXGZu6wUsk+ARn3eB+CEYFkXA4KjDfgyNhOpXO2yWwdPsWbLLak93jmi+L5Jq7B7Ni2fuJEtI86QWJB1yXMdwNE6hq2ZNqtvd9Dw0JNyAClUJ8it7FyuTBDoZi4Ri9rwU+3mXmkA= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1579779907; 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=oRnengYz+E1QG+aurkmA9qvFCtPzSzte9Ze2tVvi5LU=; b=lt3hyy1vuOB026gROFra8HZW36IEoT3yxd5PuBJHGUQAnbbDBwuxgp7/+cfr3UduPylf5o6YIygJCW0UvYZ/gdXB/axlHfT7rw8BdcBnp6FE9/RhgYWMQ1iBbpTo1BnO28WFBAx5/84zC/s0ePG63bAOIJ6aG7JC0zOKZwV9zj0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.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 1579779907090835.9224142561545; Thu, 23 Jan 2020 03:45:07 -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-58-5us78kRtODWqecE_KBl0mw-1; Thu, 23 Jan 2020 06:44:10 -0500 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 05139477; Thu, 23 Jan 2020 11:44:05 +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 CC56E60C88; Thu, 23 Jan 2020 11:44: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 866C98590C; Thu, 23 Jan 2020 11:44: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 00NBhuk7025414 for ; Thu, 23 Jan 2020 06:43:56 -0500 Received: by smtp.corp.redhat.com (Postfix) id 062E685750; Thu, 23 Jan 2020 11:43:56 +0000 (UTC) Received: from domokun.gsslab.fab.redhat.com (unknown [10.33.8.110]) by smtp.corp.redhat.com (Postfix) with ESMTP id 68DF785754; Thu, 23 Jan 2020 11:43:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1579779905; 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=oRnengYz+E1QG+aurkmA9qvFCtPzSzte9Ze2tVvi5LU=; b=LPUW5hMtPU5yeGickOGVuwJeUZEwPH6yZsU7i8IQNmm/1l7xQOCotpX3VXpf5OX4sYyxUg i7TiNv3IGTCQoh3w54NWwsdATWcmgwa8gJiJ8ChexI0rn1frLXlQUHX3VWOgcCeht2pIcn n6somyF/9HmdFMPDfVjUJwyWcCk2x3s= From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= To: libvir-list@redhat.com Subject: [libvirt PATCH 14/32] src: replace mkdir() with g_mkdir() Date: Thu, 23 Jan 2020 11:43:07 +0000 Message-Id: <20200123114325.3860881-15-berrange@redhat.com> In-Reply-To: <20200123114325.3860881-1-berrange@redhat.com> References: <20200123114325.3860881-1-berrange@redhat.com> 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.12 X-MC-Unique: 5us78kRtODWqecE_KBl0mw-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" g_mkdir() provides portability to Windows platforms. Signed-off-by: Daniel P. Berrang=C3=A9 --- src/util/virfile.c | 2 +- tests/virlockspacetest.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/util/virfile.c b/src/util/virfile.c index 51a0d40b50..d0e0062aa7 100644 --- a/src/util/virfile.c +++ b/src/util/virfile.c @@ -3029,7 +3029,7 @@ virFileMakePathHelper(char *path, mode_t mode) *p =3D '/'; } =20 - if (mkdir(path, mode) < 0 && errno !=3D EEXIST) + if (g_mkdir(path, mode) < 0 && errno !=3D EEXIST) return -1; =20 return 0; diff --git a/tests/virlockspacetest.c b/tests/virlockspacetest.c index 57deb288a9..40395e8c72 100644 --- a/tests/virlockspacetest.c +++ b/tests/virlockspacetest.c @@ -300,7 +300,7 @@ static int testLockSpaceResourceLockPath(const void *ar= gs G_GNUC_UNUSED) if (!(lockspace =3D virLockSpaceNew(NULL))) goto cleanup; =20 - if (mkdir(LOCKSPACE_DIR, 0700) < 0) + if (g_mkdir(LOCKSPACE_DIR, 0700) < 0) goto cleanup; =20 if (virLockSpaceCreateResource(lockspace, LOCKSPACE_DIR "/foo") < 0) --=20 2.24.1