Skip to content

Commit 17e242a

Browse files
committed
Remove CHAR
As with USHORT, keep using C types for BSD socket APIs.
1 parent 396be64 commit 17e242a

File tree

1 file changed

+3
-4
lines changed
  • library/std/src/sys/pal/windows

1 file changed

+3
-4
lines changed

library/std/src/sys/pal/windows/c.rs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ pub use windows_sys::*;
1919

2020
pub type DWORD = c_ulong;
2121
pub type SIZE_T = usize;
22-
pub type CHAR = c_char;
2322
pub type ULONG = c_ulong;
2423

2524
pub type LPCVOID = *const c_void;
@@ -141,9 +140,9 @@ pub struct MOUNT_POINT_REPARSE_BUFFER {
141140
#[repr(C)]
142141
pub struct SOCKADDR_STORAGE_LH {
143142
pub ss_family: ADDRESS_FAMILY,
144-
pub __ss_pad1: [CHAR; 6],
143+
pub __ss_pad1: [c_char; 6],
145144
pub __ss_align: i64,
146-
pub __ss_pad2: [CHAR; 112],
145+
pub __ss_pad2: [c_char; 112],
147146
}
148147

149148
#[repr(C)]
@@ -152,7 +151,7 @@ pub struct sockaddr_in {
152151
pub sin_family: ADDRESS_FAMILY,
153152
pub sin_port: c_ushort,
154153
pub sin_addr: in_addr,
155-
pub sin_zero: [CHAR; 8],
154+
pub sin_zero: [c_char; 8],
156155
}
157156

158157
#[repr(C)]

0 commit comments

Comments
 (0)