Skip to content

Commit 180d20b

Browse files
committed
Apply deprecation to linux uses of RLIM_NLIMITS
The deprecation for RLIM_NLIMITS was unintentionally removed in ad3f860.
1 parent f141a1a commit 180d20b

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

src/unix/linux_like/android/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1559,6 +1559,7 @@ pub const RLIMIT_MSGQUEUE: ::c_int = 12;
15591559
pub const RLIMIT_NICE: ::c_int = 13;
15601560
pub const RLIMIT_RTPRIO: ::c_int = 14;
15611561

1562+
#[deprecated(since = "0.2.64", note = "Not stable across OS versions")]
15621563
pub const RLIM_NLIMITS: ::c_int = 16;
15631564
pub const RLIM_INFINITY: ::rlim_t = !0;
15641565

src/unix/linux_like/linux/arch/generic/mod.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -277,16 +277,19 @@ cfg_if! {
277277
pub const RLIMIT_NICE: ::c_int = 13;
278278
pub const RLIMIT_RTPRIO: ::c_int = 14;
279279
pub const RLIMIT_RTTIME: ::c_int = 15;
280+
#[deprecated(since = "0.2.64", note = "Not stable across OS versions")]
280281
pub const RLIM_NLIMITS: ::c_int = 15;
281282
pub const RLIMIT_NLIMITS: ::c_int = RLIM_NLIMITS;
282283
}
283284
}
284285

285286
cfg_if! {
286287
if #[cfg(target_env = "gnu")] {
288+
#[deprecated(since = "0.2.64", note = "Not stable across OS versions")]
287289
pub const RLIM_NLIMITS: ::__rlimit_resource_t = 16;
288290
}
289291
else if #[cfg(target_env = "uclibc")] {
292+
#[deprecated(since = "0.2.64", note = "Not stable across OS versions")]
290293
pub const RLIM_NLIMITS: ::__rlimit_resource_t = 15;
291294
}
292295
}

0 commit comments

Comments
 (0)