Date: Thu, 16 Jun 2011 11:05:56 +0400 From: Sergey Kandaurov <pluknet@freebsd.org> To: David Xu <davidxu@freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r223136 - head/lib/libc/gen Message-ID: <BANLkTikVohK8d644mP6HoaeT93UTH1_0Rg@mail.gmail.com> In-Reply-To: <201106160222.p5G2MOrQ008203@svn.freebsd.org> References: <201106160222.p5G2MOrQ008203@svn.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On 16 June 2011 06:22, David Xu <davidxu@freebsd.org> wrote: > Author: davidxu > Date: Thu Jun 16 02:22:24 2011 > New Revision: 223136 > URL: http://svn.freebsd.org/changeset/base/223136 > > Log: > =A0Use size of int to fetch sysctl kern.sched.cpusetsize because it had > =A0switched from long to int type in kernel. > > =A0Fixed by: pluknet > > Modified: > =A0head/lib/libc/gen/sysconf.c > > Modified: head/lib/libc/gen/sysconf.c > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D > --- head/lib/libc/gen/sysconf.c Thu Jun 16 02:16:53 2011 =A0 =A0 =A0 =A0(= r223135) > +++ head/lib/libc/gen/sysconf.c Thu Jun 16 02:22:24 2011 =A0 =A0 =A0 =A0(= r223136) > @@ -599,11 +599,11 @@ yesno: > > =A0#ifdef _SC_CPUSET_SIZE > =A0 =A0 =A0 =A0case _SC_CPUSET_SIZE: > - =A0 =A0 =A0 =A0 =A0 =A0 =A0 len =3D sizeof(lvalue); > - =A0 =A0 =A0 =A0 =A0 =A0 =A0 if (sysctlbyname("kern.sched.cpusetsize", &= lvalue, &len, NULL, > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 len =3D sizeof(value); > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 if (sysctlbyname("kern.sched.cpusetsize", &= value, &len, NULL, > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A00) =3D=3D -1) > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0return (-1); > - =A0 =A0 =A0 =A0 =A0 =A0 =A0 return (lvalue); > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 return ((long)value); > =A0#endif > > =A0 =A0 =A0 =A0default: > Thanks! --=20 wbr, pluknet
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?BANLkTikVohK8d644mP6HoaeT93UTH1_0Rg>