|
Message-ID: <20110705004424.GD520@brightrain.aerifal.cx> Date: Mon, 4 Jul 2011 20:44:24 -0400 From: Rich Felker <dalias@...ifal.cx> To: musl@...ts.openwall.com Subject: cluts - posix_memalign test I recently fixed the issue with musl's posix_memalign not returning failure when the align argument is smaller than sizeof(size_t), but cluts is still throwing an error in that case: W:posix_memalign returned EINVAL, but gave a non-NULL pointer (alignment=1) I believe this error is mistaken. posix_memalign is not giving a non-NULL pointer to the caller. Rather the caller is seeing the value it wrote to the pointer before making the call. I suppose some versions of posix_memalign might clear the pointer to null if allocation fails, but I could find no text in the standard that requires or even allows posix_memalign to modify the pointer when it fails, so at present musl does not touch it. I'd welcome input from anyone who has a good argument that this is incorrect, but short of that, I think cluts is checking a condition that need not (and maybe can't) be true. Rich
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.