diff options
author | deischen <deischen@FreeBSD.org> | 2001-12-18 02:02:59 +0000 |
---|---|---|
committer | deischen <deischen@FreeBSD.org> | 2001-12-18 02:02:59 +0000 |
commit | 07b826ed269a3fa089c7e6f2c0041501095a0ef9 (patch) | |
tree | 1330dcee4073e51059550bcd1622e50c3b336afa /lib/libc_r | |
parent | 6e9f1df98f816467a63dc5b41cea58f28843e390 (diff) | |
download | FreeBSD-src-07b826ed269a3fa089c7e6f2c0041501095a0ef9.zip FreeBSD-src-07b826ed269a3fa089c7e6f2c0041501095a0ef9.tar.gz |
Fix the retrieval of USRSTACK via sysctl so that it works for 64-bit
archs. This should fix libc_r on alpha.
Submitted by: Bernd Walter <ticso@cicely9.cicely.de>
Diffstat (limited to 'lib/libc_r')
-rw-r--r-- | lib/libc_r/uthread/uthread_init.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libc_r/uthread/uthread_init.c b/lib/libc_r/uthread/uthread_init.c index 30ec765..cac38dc 100644 --- a/lib/libc_r/uthread/uthread_init.c +++ b/lib/libc_r/uthread/uthread_init.c @@ -269,9 +269,9 @@ _thread_init(void) /* Find the stack top */ mib[0] = CTL_KERN; mib[1] = KERN_USRSTACK; - len = sizeof (int); + len = sizeof (_usrstack); if (sysctl(mib, 2, &_usrstack, &len, NULL, 0) == -1) - _usrstack = USRSTACK; + _usrstack = (void *)USRSTACK; /* * Create a red zone below the main stack. All other stacks are * constrained to a maximum size by the paramters passed to |