Skip to content

Commit 4d73c77

Browse files
committed
Use __xpg_strerror_r on cygwin
1 parent 701066a commit 4d73c77

File tree

1 file changed

+6
-1
lines changed
  • library/std/src/sys/pal/unix

1 file changed

+6
-1
lines changed

library/std/src/sys/pal/unix/os.rs

+6-1
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,12 @@ pub fn error_string(errno: i32) -> String {
119119
unsafe extern "C" {
120120
#[cfg_attr(
121121
all(
122-
any(target_os = "linux", target_os = "hurd", target_env = "newlib"),
122+
any(
123+
target_os = "linux",
124+
target_os = "hurd",
125+
target_env = "newlib",
126+
target_os = "cygwin"
127+
),
123128
not(target_env = "ohos")
124129
),
125130
link_name = "__xpg_strerror_r"

0 commit comments

Comments
 (0)