Skip to content

Commit

Permalink
Lower limits in setrlimit example
Browse files Browse the repository at this point in the history
The current value causes the doc test to fail on Fedora 34 for
unprivileged users.
  • Loading branch information
rtzoeller committed Sep 20, 2021
1 parent e94bf0e commit 389185e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/sys/resource.rs
Original file line number Diff line number Diff line change
Expand Up @@ -200,8 +200,8 @@ pub fn getrlimit(resource: Resource) -> Result<(Option<rlim_t>, Option<rlim_t>)>
/// ```
/// # use nix::sys::resource::{setrlimit, Resource};
///
/// let soft_limit = Some(1024);
/// let hard_limit = Some(1048576);
/// let soft_limit = Some(512);
/// let hard_limit = Some(1024);
/// setrlimit(Resource::RLIMIT_NOFILE, soft_limit, hard_limit).unwrap();
/// ```
///
Expand Down

0 comments on commit 389185e

Please sign in to comment.