Function lrs::process::set_resource_limit

Sets a resource limit.

Syntax

fn set_resource_limit(process: i32, resource: Resource, soft: u64, hard: u64) -> Result<(u64, u64), Errno>

Arguments

NameDescription
process

The process whose resource limit to set.

resource

The resource whose limit to set.

soft

The new soft limit.

hard

The new hard limit.

Return value

Returns the old soft limit in the first slot and the old hard limit in the second slot.

See also