|
Message-ID: <4E1DC70F.7000501@gmail.com> Date: Wed, 13 Jul 2011 18:25:51 +0200 From: Luka Marčetić <paxcoder@...il.com> To: musl@...ts.openwall.com Subject: Re: cluts review On 07/13/2011 03:38 PM, Rich Felker wrote: > Since the tests are > testing a POSIX environment, -D_POSIX_C_SOURCE=200809L (or even > -D_XOPEN_SOURCE=700) should be in the CFLAGS. > How about I just put define POSIX_C_SOURCE 200809L everywhere in the header, that should do the trick, right? If I put it as a flag, it might not be clear to someone who just yanks a test collection/source file out of the suite. *shrugs* >> - act.sa_flags = SA_NODEFER; >> + act.sa_flags = 0; > This was being used as part of the longjmp trick. Can you remind me what this does exactly? I can't remember anymore, seemed to me it really was not needed. man says so as to not prevent the signal handler from (paraphrasing:) calling a signal itself. I don't need this, but you probably suggested it for some other reason then. Please do remind me. Thanks. > By the way, there are a lot of warnings about local vars potentially > clobbered by longjmp. Those are worth checking out. I found gcc was > pretty strict about breaking my code in the dynamic linker when I > broke the rules for longjmp... These result from the -02 parameter. -Wall and -Wextra should report nothing. I checked buf.c for clobbering, and corrected what was necessary. There might be some other files where the same is needed, will look into then. > *asprintf is not portable because it's a GNU extension, but it's > trivial to implement it as a wrapper for vsnprintf which is standard. > See the code in musl for an example of how to do it. Oh. That might be why I haven't heard of it. Well, I am using the other one for sreturnf... Thanks Luka.
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.