From nobody Fri Sep 12 11:56:26 2025 X-Original-To: freebsd-current@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4cNXvl4rvzz67Mg4 for ; Fri, 12 Sep 2025 11:56:35 +0000 (UTC) (envelope-from olce@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cNXvl4BJhz3cB3; Fri, 12 Sep 2025 11:56:35 +0000 (UTC) (envelope-from olce@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757678195; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=tpjWyIPOEcDdR5NCcoNPoL+Hn0Y3Lg4QZWdS/ec1t4Q=; b=voo/f4qhoF22oN09ocpuOiPcFo6UN0+H68j90/2OgButZs0OnXI+t6rQUwE8Xkwg8iBlzR 5Jb1czS0oQdH7sv9ymP6+0aRLNwWBG0WoJuVBaS5BiHY+vQQhyfmtwiJOZGhfojKGRkl4p M02qhFhCkDctRW14/Y/xzYfCm086y0vNwooVVopmTa816hGG1Hal2WPpZ7iW0WyJ103vzA sCEL3s6XbboKIirnmAWVwQpd0kPX+M66dDANEdOlRNqycXBfLRs2s3JCnUbmCZW/X7mv4d xt2Qw4MdRykdQN8R6z5Wt/5MJ9GxFh74pdaU/5G/MuupDByFV4TBagUtbL01SA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1757678195; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=tpjWyIPOEcDdR5NCcoNPoL+Hn0Y3Lg4QZWdS/ec1t4Q=; b=lIx/rk2p1pd1FFTHQmoFY8Ig3fRYXsXbHDpUpjlMK+ze01ggwtlCsPQtZkO+fLnHmgj6xq md9uxDwczpPGg7QBJl/yFt2IK2Z6eQc4wDMTJEL5V1t+1/F92OjszAXqY7wyOSXPk4T0dK sJib4mZ3vLzXDg7dbWyl/OAUJeGsUPUC0XdQwyMVaTbuKYBvj28fiWyDSpKv+SGGNw8H3V 0QusFFazB8ecB4p0Cvvaa5t7wqjH6keJBF1uEy1gdCDiAyPFRSfmPzCgFjihCAakApG1lS d/Ahleez9AKICg4hutLqxYxKd1U47glvdB45VeB/QYOlR55idI+MvFeHNfJrXw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1757678195; a=rsa-sha256; cv=none; b=VUhXYsRHuCVwbKl2E1enAluKMFluJlwAD0EoX1Un8spR3QiXeYcDV/TJxhWv1pukQWFJ+V l4CMoZgT6gFsBPwtmIvEaTwrBfJTEkVEOXK6TeeSVCRJDalZqH5priNWr1Sa2OCDqGN0ik y/Y2vbbBXFak6hsMbf3EWjCOL/HEKbpoc6I+ZM9CYsENJbcLSXR9zk442YZT7jASYR0pTS H5iVvUGcyJ9buirVcDH8ZpTt8TFgfP2mxi8xOyg0I3zRJDc4Bqn31O5TsN/Zovj/KaNaLw Cc51QCsKRA0YRxdwKtlsRhPKV36AjLrjEwwT+prQcyx8I0bQbm1meUfrqcYCOQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from ravel.localnet (aclermont-ferrand-653-1-222-123.w90-14.abo.wanadoo.fr [90.14.66.123]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: olce/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4cNXvk6572zk3M; Fri, 12 Sep 2025 11:56:34 +0000 (UTC) (envelope-from olce@freebsd.org) From: Olivier Certner To: Bob Bishop , Dag-Erling =?UTF-8?B?U23DuHJncmF2?= Cc: FreeBSD Current , Alan Somers , Toomas Soome Subject: Re: git: d549de769055 - main - libc: Remove readdir_r(3) [This broke building rust 1.88] Date: Fri, 12 Sep 2025 13:56:26 +0200 Message-ID: <6053312.Zv9zXsTiuT@ravel> In-Reply-To: <86qzwcgcmp.fsf@ltc.des.dev> References: <1F6A4621-1505-4F78-97C6-85EA556B2165.ref@yahoo.com> <0F481EDD-24F4-4F2C-BCBB-9B016DD313F3@gid.co.uk> <86qzwcgcmp.fsf@ltc.des.dev> List-Id: Discussions about the use of FreeBSD-current List-Archive: https://lists.freebsd.org/archives/freebsd-current List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-current@FreeBSD.org MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart2759553.TYJnH3iKXO"; micalg="pgp-sha384"; protocol="application/pgp-signature" --nextPart2759553.TYJnH3iKXO Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="utf-8"; protected-headers="v1" From: Olivier Certner Date: Fri, 12 Sep 2025 13:56:26 +0200 Message-ID: <6053312.Zv9zXsTiuT@ravel> In-Reply-To: <86qzwcgcmp.fsf@ltc.des.dev> MIME-Version: 1.0 Hi, > The only argument in favor of readdir_r() was thread safety because some > readdir() implementations used to return a pointer to a static buffer, > but was never the case for FreeBSD. True, but most software isn't written for FreeBSD specifically, and some intends to be more or less portable. > Our readdir() is thread-safe as long as you don't have multiple threads operating on the same DIR. Only the latest POSIX release (Issue 8, 2024) amended the wording to unequivocally require that, even if previous versions could be considered to hint at that. I did not survey some other open-source implementations, maybe in practice they all meet that requirement. But even if they do, we don't really know about proprietary systems. Also, readdir_r() has just been obsoleted in Issue 8, only a year ago, so again I don't understand the hurry in actually *removing* it unless there is a clear security issue or it is actively obstructing some other grand plan. Hence, I'll point again to https://reviews.freebsd.org/D52474. Thanks and regards. -- Olivier Certner --nextPart2759553.TYJnH3iKXO Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part. Content-Transfer-Encoding: 7Bit -----BEGIN PGP SIGNATURE----- iQIzBAABCQAdFiEEmNCxHjkosai0LYIujKEwQJceJicFAmjECmoACgkQjKEwQJce Jif5UA//YVbO43Irdyq58D1vgSS7euVHahh9Rjoptdx/NrP6NG1RtC24D6FA5HH3 RosLp+W6D5+vLXIIV+XHJea8BsI4TIVMoWPKdA5Tqzm2XEk4/6yf3luLOOlu7pdi OMsafl8elSM0AT6lEym+X/3CrlH82Us7Iv/rMEG4p4aWL2y4F61ZkmKlLnC9IzSr wGYcreIt5XHR/9zqcPSgyAmHXIpjrWz1V5bM/F/TAZ4PtlCVwM2o7tgHChMEKU3i gm4zZvTMrmVlO34LCeXZoBtr5hKoznesLX8tdm0ijbFs2MtWQ175TM38++2MIUVQ /g1oFeKj2zf2GnpZnkxachbX9+oZvWPEjm3W9rtfKpHmiRv2RxdbEm1xLFzysaJm pp6sJqBKuSAuDbuhsJeBS0ozEmWwkPF7UB+ZRY+7TNmXwospv5D6wOhfNExpHrQi wwa6QCX9RtqM9ObFfzNyC2f3VD0FUmmT1frxK27O9bsa8c/OTzykRFxqfU+Acp/I 2BseHnym3hDzk3WZ9LpP38cTpjbkI9QYS67K6qjKHpS5hpTddMGY7CaQ/uj5Orlo DbTQ+HNoInM7qx3xzpmQN6AT5WCxzCFeqiSTi5VVs1uKOKZdtBvKPdHNU7WhZn1Y QTFvkQPD/BzKZPcCLJx70plxafCmyaPffbzCWkQEuQ2ZKc9w4Oo= =ePn7 -----END PGP SIGNATURE----- --nextPart2759553.TYJnH3iKXO--