https://bugs.kde.org/show_bug.cgi?id=433439

--- Comment #5 from Mark Wielaard <m...@klomp.org> ---
(In reply to Paul Floyd from comment #4)
> Why do you think making sysctl newp const might be unsafe?
> 
> The signature on FreeBSD is
> 
>      int
>      sysctl(const int *name, u_int namelen, void *oldp, size_t *oldlenp,
>          const void *newp, size_t newlen);
> 
> On Darwin it is non--const, but there are only two calls to it both with
> NULL arguments for newp.
> 
> Either way newp gets cast to (UWord).
> 
> I prefer to keep it const as this makes the interface clearer (an optional
> input-only argument).

But it doesn't match the actual VG_(sysctl) function in coregrind/m_libcproc.c
we actually use, so it causes compile errors.

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to