core: Fix BSD breakage, I hope

This commit is contained in:
Tim Chevalier 2013-02-18 20:12:17 -08:00
parent 6351515d98
commit dc30cc356b

View File

@ -374,6 +374,7 @@ pub fn self_exe_path() -> Option<Path> {
let mib = ~[CTL_KERN as c_int,
KERN_PROC as c_int,
KERN_PROC_PATHNAME as c_int, -1 as c_int];
let mut sz = sz;
sysctl(vec::raw::to_ptr(mib), vec::len(mib) as c_uint,
buf as *mut c_void, &mut sz, ptr::null(),
0u as size_t) == (0 as c_int)