readlink -f still segfaults
Bernhard Fischer
rep.nop at aon.at
Fri May 5 09:44:11 UTC 2006
On Fri, May 05, 2006 at 12:29:26PM +0200, Natanael Copa wrote:
>On Fri, 2006-05-05 at 11:29 +0200, Natanael Copa wrote:
>> I discovered my hotplug scripts fails caused by readlink segfaulting. I
>> googled and found that it has been seen before:
>>
>> http://www.busybox.net/lists/busybox/2006-January/017795.html
>>
>> Looks like it never got a conclusion.
>
>The problem is the realpath(...., NULL) gnu extension mentioned here:
>http://www.busybox.net/lists/busybox/2006-January/017777.html
>
>The attached patch fixes the problem by calling xmalloc instead of
>relying on realpath to do it.
>
>Please commit (also to busybox_1_1_stable)
Looks ok to me.
Can you please add a
if (ENABLE_CLEANUP && (opt & READLINK_FLAG_f))
free;
and make a simple
testsuite/readlink.tests
That'd be awesome!
More information about the busybox
mailing list