Change return type of readdir to *mut ::dirent
Apparently a lot of libc's don't put "const" on the return type for readdir, which causes type mismatch.
This commit is contained in:
parent
e010078127
commit
02990f2fd2
@ -352,7 +352,7 @@ extern {
|
||||
pub fn opendir(dirname: *const c_char) -> *mut ::DIR;
|
||||
#[cfg_attr(target_os = "macos", link_name = "readdir$INODE64")]
|
||||
#[cfg_attr(target_os = "netbsd", link_name = "__readdir30")]
|
||||
pub fn readdir(dirp: *mut ::DIR) -> *const ::dirent;
|
||||
pub fn readdir(dirp: *mut ::DIR) -> *mut ::dirent;
|
||||
#[cfg_attr(target_os = "macos", link_name = "readdir_r$INODE64")]
|
||||
#[cfg_attr(target_os = "netbsd", link_name = "__readdir_r30")]
|
||||
pub fn readdir_r(dirp: *mut ::DIR, entry: *mut ::dirent,
|
||||
|
Loading…
Reference in New Issue
Block a user