Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 16 Jan 2009 00:53:19 -0800
From:      Garrett Cooper <yanefbsd@gmail.com>
To:        Jacques Fourie <jacques.fourie@gmail.com>
Cc:        "amd64@freebsd.org" <amd64@freebsd.org>, Hackers freeBSD <freebsd-hackers@freebsd.org>
Subject:   Re: Confused by segfault with legitimate call to strerror(3) on amd64 / sysctl(3) setting `odd' errno's
Message-ID:  <7d6fde3d0901160053y22b2f9c9vb37d0f0621c2a7c9@mail.gmail.com>
In-Reply-To: <be2f52430901160047j18172bb9ne75066de0094e565@mail.gmail.com>
References:  <7d6fde3d0901160041n55466290l55f737d274a40895@mail.gmail.com> <7d6fde3d0901160044x4d7735cep16f032cd99dbc835@mail.gmail.com> <be2f52430901160047j18172bb9ne75066de0094e565@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Jan 16, 2009 at 12:47 AM, Jacques Fourie
<jacques.fourie@gmail.com> wrote:
>
> You need to initialize len to the number of entries in the mib array.
> Try adding 'len = 4' before calling sysctlnametomib() and see if your
> issues go away.

    Ok, that solution works (I think). So, problem 2 down. Now: what
about the segfaulting strerror(3) call on amd64 ;\?
-Garrett



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?7d6fde3d0901160053y22b2f9c9vb37d0f0621c2a7c9>