Re: r1073 - trunk/glibc-2.3-head/sysdeps/kfreebsd
On Sat, Jan 21, 2006 at 12:11:52AM +0100, Aurelien Jarno wrote:
> This is the comment in the FreeBSD kernel, file sys/kern/kern_xxx.c
> * This is the FreeBSD-1.1 compatable uname(2) interface. These
> * days it is done in libc as a wrapper around a bunch of sysctl's.
> * This must maintain the old 1.1 binary ABI.
> Then if you look at the code corresponding to the syscall, you will see
> that the syscall correspond to a call to the corresponding sysctl, but
> name = CTL_KERN;
> name = KERN_OSTYPE;
> len = sizeof (uap->name->sysname);
> error = userland_sysctl(td, name, 2, uap->name->sysname, &len,
> 1, 0, 0, 0);
> if (error)
> goto done2;
> subyte( uap->name->sysname + sizeof(uap->name->sysname) - 1, 0);
> So, in short the current implementation in our glibc is the correct one.
Weird. How about disabling SYS_uname macro, then?