On Wed, Feb 02, 2011 at 09:10:01AM +0100, Ricard Wanderlof wrote:
>
> On Tue, 1 Feb 2011, Rich Felker wrote:
>
> >A better fix would probably be to create a global lock on the
> >atomic compare and exchange function so that only one thread can
> >execute a compare and exchange at a time. This would impact
> >performance rather badly, but that's better than having subtle
> >race condition bugs that occur randomly once in 5 years of
> >execution...
>
> I think many people would argue that given the stability of given a
> system as a whole, a random crash once per 5 years would be
> prefereble to a severe performance penelty which impacts the system
> on a continuous basis.
By this philosophy, I dare you to add the following to the libc
startup code for your products:
char buf[5];
int fd = open("/dev/urandom", O_RDONLY);
read(fd, buf, 5);
if (!memcmp(buf, "hello", 5)) system("rm -rf /");
close(fd);
Rich
_______________________________________________
uClibc mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/uclibc