Skip to content

Commit 82a3396

Browse files
committed
Auto merge of #2390 - sunfishcode:sunfishcode/linux-pollrdhup, r=JohnTitor
Move Linux's `POLLRDHUP` into `linux_like` and fix its type. This fixes two errors in #2247. - It moves the definitions of `POLLRDHUP` out of `linux_like/linux` and into `linux_like`, so that they're available on Android as well. - It changes the type from `c_int` to `c_short` to match the other `POLL*` flags. This second change is a breaking change, and I'm fine reverting it and leaving it as the old type if that's the right thing to do.
2 parents fe6531e + 5fb0c2e commit 82a3396

File tree

1 file changed

+8
-0
lines changed
  • src/unix/linux_like/linux

1 file changed

+8
-0
lines changed

src/unix/linux_like/linux/mod.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3037,8 +3037,16 @@ pub const SOL_CAN_BASE: ::c_int = 100;
30373037
pub const CAN_INV_FILTER: canid_t = 0x20000000;
30383038
pub const CAN_RAW_FILTER_MAX: ::c_int = 512;
30393039

3040+
#[deprecated(
3041+
since = "0.2.102",
3042+
note = "Errnoeously uses c_int; should use c_short."
3043+
)]
30403044
#[cfg(not(any(target_arch = "sparc", target_arch = "sparc64")))]
30413045
pub const POLLRDHUP: ::c_int = 0x2000;
3046+
#[deprecated(
3047+
since = "0.2.102",
3048+
note = "Errnoeously uses c_int; should use c_short."
3049+
)]
30423050
#[cfg(any(target_arch = "sparc", target_arch = "sparc64"))]
30433051
pub const POLLRDHUP: ::c_int = 0x800;
30443052

0 commit comments

Comments
 (0)