From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from esa2.mentor.iphmx.com (esa2.mentor.iphmx.com [68.232.141.98]) by sourceware.org (Postfix) with ESMTPS id C0A053858D20 for ; Fri, 20 Jan 2023 17:49:12 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org C0A053858D20 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=mentor.com X-IronPort-AV: E=Sophos;i="5.97,232,1669104000"; d="scan'208";a="95168959" Received: from orw-gwy-01-in.mentorg.com ([192.94.38.165]) by esa2.mentor.iphmx.com with ESMTP; 20 Jan 2023 09:49:10 -0800 IronPort-SDR: KI6C/wtX5jLLeY5Zt4bhDKKSbouDHA5nihWrCfg8HxRoygzUCMxFzQwfoYUbe89JMiw5P8wC57 2JL93+122WVW4Af71olf4+lMgxBYcKCQ9JaS8jleJTecplFl/jbiuy6QNisb0TRzCZUEBxVvgW YUxoDo7WEz26A4/Y1DmQpus+OmnRdrEbWGUMdG6Z2tID8UiSSyxLCQpX3QaSfUhPac63BfGJnA Gcc19VFIQczEuudgwmlcunZjNm15sDD1rniEOSzwVSqQ55RKvms2iNZADh6r6JBvuu0By6TckW DUU= Date: Fri, 20 Jan 2023 17:49:04 +0000 From: Joseph Myers To: Alejandro Colomar CC: , Alejandro Colomar , , =?ISO-8859-15?Q?Bastien_Roucari=E8s?= , Eric Blake , Zack Weinberg , Stefan Puiu , Igor Sysoev Subject: Re: [PATCH v2] socket: Implement sockaddr_storage with an anonymous union In-Reply-To: <20230120134043.10247-1-alx@kernel.org> Message-ID: References: <20230120134043.10247-1-alx@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" X-Originating-IP: [137.202.0.90] X-ClientProxiedBy: svr-ies-mbx-13.mgc.mentorg.com (139.181.222.13) To svr-ies-mbx-11.mgc.mentorg.com (139.181.222.11) X-Spam-Status: No, score=-3108.8 required=5.0 tests=BAYES_00,HEADER_FROM_DIFFERENT_DOMAINS,KAM_DMARC_STATUS,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS,TXREP autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On Fri, 20 Jan 2023, Alejandro Colomar via Libc-alpha wrote: > This patch fixes sockaddr_storage to remove UB on its uses and make it > that structure that everybody should be using. It also allows removing > many casts in code that needs to pass a sockaddr as a side effect. This patch only changes the fallback version of bits/socket.h that would be used by a new OS port that doesn't have its own, not either of the versions that any current glibc port actually uses (sysdeps/unix/sysv/linux/bits/socket.h and sysdeps/mach/hurd/bits/socket.h). -- Joseph S. Myers joseph@codesourcery.com