diff --git a/Doc/library/resource.rst b/Doc/library/resource.rst --- a/Doc/library/resource.rst +++ b/Doc/library/resource.rst @@ -50,9 +50,11 @@ .. function:: setrlimit(resource, limits) - Sets new limits of consumption of *resource*. The *limits* argument must be a - tuple ``(soft, hard)`` of two integers describing the new limits. A value of - ``-1`` can be used to specify the maximum possible upper limit. + Sets new limits of consumption of *resource*. The *limits* argument must be + a tuple ``(soft, hard)`` of two integers describing the new limits. A value + of ``-1`` can be used to request an infinite limit; this may result in an + exception if the hard limit or system limit for the specified resource is a + limited value. Raises :exc:`ValueError` if an invalid resource is specified, if the new soft limit exceeds the hard limit, or if a process tries to raise its hard limit