From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=MAILING_LIST_MULTI, RCVD_IN_MSPIKE_H2,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 27084 invoked from network); 2 May 2023 23:20:27 -0000 Received: from second.openwall.net (193.110.157.125) by inbox.vuxu.org with ESMTPUTF8; 2 May 2023 23:20:27 -0000 Received: (qmail 32669 invoked by uid 550); 2 May 2023 23:20:23 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Reply-To: musl@lists.openwall.com Received: (qmail 32607 invoked from network); 2 May 2023 23:20:22 -0000 Date: Tue, 2 May 2023 19:20:09 -0400 From: Rich Felker To: =?utf-8?B?SuKCkeKCmeKCmw==?= Gustedt Cc: musl@lists.openwall.com Message-ID: <20230502232009.GT4163@brightrain.aerifal.cx> References: <20230501205037.29e42745@inria.fr> <20230501194121.GS4163@brightrain.aerifal.cx> <20230502085740.23ff20d5@inria.fr> <20230502155903.30bee099@inria.fr> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20230502155903.30bee099@inria.fr> User-Agent: Mutt/1.5.21 (2010-09-15) Subject: Re: [musl] patches for C23 On Tue, May 02, 2023 at 03:59:03PM +0200, Jₑₙₛ Gustedt wrote: > on Tue, 2 May 2023 08:57:40 +0200 you (Jₑₙₛ Gustedt > ) wrote: > > > I'll also setup a git repository for those who would be willing to > > test the whole. Just be aware that is really testing and review, not > > yet ready for direct inclusion. So probably this will be rebased > > several times. > > So this can now be found here > > https://icube-forge.unistra.fr/icps/musl/ > > with my additional branch called "c23". I also put on tags for what I > think might be good groups to treat together. An overview should be > accessible here > > https://icube-forge.unistra.fr/icps/musl/-/network/c23?ref_type=heads > > Let me know if you have any problems in accessing this. > > I will then post the patches on the ML later, probably need some time > for that to do it right. One quick find, in https://icube-forge.unistra.fr/icps/musl/-/commit/3a2b83bf32d7c94f1bf0b2b2fd6ba8b6bf980d99 - np = strtoul(r+9, &z, 10); + np = strtoul(r+9, (char**)&z, 10); is UB. Accessing a const char * as char *. I would prefer in general we just #undef any of the const-stuff-tg macros in files that use them, or just have src/include/string.h always do that. (Not really needed since musl source is written in c99 not c23, but it would be nice to have it also compile with c11 and c23 compilers, so I think the #undef is useful.) Rich