Skip to content

Commit f638893

Browse files
committed
espidf: Fix the duplicate definition of gethostname
1 parent 57a0228 commit f638893

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/unix/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1479,6 +1479,7 @@ extern "C" {
14791479
link_name = "mknod@FBSD_1.0"
14801480
)]
14811481
pub fn mknod(pathname: *const c_char, mode: mode_t, dev: crate::dev_t) -> c_int;
1482+
#[cfg(not(target_os = "espidf"))]
14821483
pub fn gethostname(name: *mut c_char, len: size_t) -> c_int;
14831484
pub fn endservent();
14841485
pub fn getservbyname(name: *const c_char, proto: *const c_char) -> *mut servent;

0 commit comments

Comments
 (0)