From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by sourceware.org (Postfix) with ESMTPS id 4A9D83858D1E for ; Wed, 8 Nov 2023 22:12:05 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 4A9D83858D1E Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=kernel.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=kernel.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 4A9D83858D1E Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2604:1380:4601:e00::1 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1699481529; cv=none; b=s5dGdPY4Buk6wajM+fa8FrwNiPjwCPoJqNvNMcLboLvmWNqr1Q00IPeL6uvLHhOx1RUtp0gE31lcZumCtate4T4LAMeNPyJuTyFUAbpDK3m3Y1jGV+hTT39q3/rs1zWkt3i8L+Jmt9Rwf/KMSkVinC206l0cP1vVyYrn6iah94Y= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1699481529; c=relaxed/simple; bh=a7pPW9JjY3KZGUjO0KYFtw0XuFqPCUb0VKr+ZHN6YxE=; h=DKIM-Signature:Date:From:To:Subject:Message-ID:MIME-Version; b=nETKS61PuCEgoUZXkj0x0wZqSStWZArqbLtx9pezDDG/38jNu7cA3skVXK9uXm9LplVYXEOhGAZQ9Fd3jVWsVUsoWnoEqyCsYtUqrevB3t+vQQl5yF0F81oJY5YgdDeJ695H/Ebc1Jj9eWlgWOH46kuIlskhnDpzYEOsqnUEMBk= ARC-Authentication-Results: i=1; server2.sourceware.org Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by ams.source.kernel.org (Postfix) with ESMTP id AC0AEB81ED1; Wed, 8 Nov 2023 22:12:03 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9C733C433C8; Wed, 8 Nov 2023 22:12:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1699481522; bh=a7pPW9JjY3KZGUjO0KYFtw0XuFqPCUb0VKr+ZHN6YxE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=ODcBMqVTRGFboR0flz5W6j4uVO/uTgXrfbMgrD0tvB6SQEsJpBzXKFMRN1mTBTVTj aj0NK9e0CDg0HNFE4tl9cq7StAodq9CID62RPE2ZyKlZ+cpgb0OG3Z1qYDWJ9tywNu lvuSU22NbGE8TheW2Z7Egc5mXdHQGzfaZGm3coxgalZQ1H2POxWO1f3DFxIjRYjhTM 7SwEyswh5LZoOMeHNpO80goy0el2aN/B+GgxZsYFzkFOkRlB9i+PwPFTGR6WKlcWxJ 795jqJmVle+RhPADmfTR4Oe4FHi3w1ip+u3XstmI7KflsIugrRwVBPfbFSh6KPbtSC bFh8NveVmLJ3w== Date: Wed, 8 Nov 2023 23:11:59 +0100 From: Alejandro Colomar To: Carlos O'Donell Cc: Zack Weinberg , GNU libc development , Jonny Grant , 'linux-man' Subject: Re: strncpy clarify result may not be null terminated Message-ID: References: <929865e3-17b4-49c4-8fa9-8383885e9904@jguk.org> <16cc15a4-cfc0-49f4-9ebf-ecf0901700ce@app.fastmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="pdD3to4i+y698yKj" Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-3.8 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: --pdD3to4i+y698yKj Content-Type: text/plain; protected-headers=v1; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Date: Wed, 8 Nov 2023 23:11:59 +0100 From: Alejandro Colomar To: Carlos O'Donell Cc: Zack Weinberg , GNU libc development , Jonny Grant , 'linux-man' Subject: Re: strncpy clarify result may not be null terminated On Wed, Nov 08, 2023 at 04:35:12PM -0500, Carlos O'Donell wrote: > On 11/8/23 10:07, Alejandro Colomar wrote: > > So we had it in ISO C in C89 and C99, and only in C11 they realized it > > had to be removed. POSIX hasn't even removed it yet! I won't hesitate > > to kill a function just because of bureaucracy. >=20 > Attempting to get consensus at an international level, across cultural bo= undaries, > use cases, workloads, and developer workflows is difficult and not intend= ed to be > bureaucracy for the sake of bureaucracy. Hi Carlos! I understand that, and respect ISO's work. I just don't think we need, as GNU or Linux projects, to be restricted to the decisions of ISO. We can realize that certain functions are bad, and mark them as deprecated in our scope. If others want to imitate (ISO might even take it as "prior art"), then great. Cheers, Alex >=20 > --=20 > Cheers, > Carlos. >=20 --=20 --pdD3to4i+y698yKj Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEE6jqH8KTroDDkXfJAnowa+77/2zIFAmVMB68ACgkQnowa+77/ 2zKO5w//XxBdgF/pdJGBZiCDZSQDqRMVTB9lQMe2ADTTn8cpi/QLxcsCZ6O4L4Na 6yY8NHHe8UZ1X2Op1GseBRoOTWls7g0O3TPAuXS05Tcxy2brq0P9GOD656debNF5 6bSXAGV0M7QYeBQxdGpcanvCpd8/m99edzGrzXeLJhrEJd/IQcI4XhHtniolkPf+ EL41Fb0lFyKJ/l73j+KP8MAz989mvIbPoM5Yd89YnCtDEsVrzZyj3NvB/kRf5gzQ xUZ+YrFYqgsTm7y2GBZN9IS7tlvaY0YcJEG3F9MZGmIZPuStIN2//awnpth1aBoe ZAFvJ1tTcB2k4crqbNbql5iiEd5VFncqirMCQ7vIjJhDkhz/vzhDCZDtsxVIMGya 2a89APMB1T+RmmiXnVENPH1RvkLjpoB1Bv9wSp8wX9X04G+hDA2RAceJMltRdkJW 3JBuytYxOK7u6Y9sZBQ84VSyqYCl/4Xey/TPepT//lV1Pu6/zV/Wif2lK0KGlbsw GZ7ArZxz9fQn/vEZkYJfm8SfbrSoL5Pm2l9UuH2pu1vURTbsoG1GUZJMTKzKz4Pt B+G8t0yV0+lXB1asHuiS1hXI+TsjDhHJXoJdswMh7Jgjt0LqSs5J9B7tYG/ET1jF JF1+rlyVLKl1sq3EZoa/cBoO9V6gpntUGGjyct/yjpDJKWn9YRM= =Orry -----END PGP SIGNATURE----- --pdD3to4i+y698yKj--