[lkml]   [2021]   [Jun]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [GIT PULL] ucounts: Count rlimits in each user namespace
Linus Torvalds <> writes:

> Why the "sigpending < LONG_MAX" test in that
> if (override_rlimit || (sigpending < LONG_MAX && sigpending <=
> task_rlimit(t, RLIMIT_SIGPENDING))) {
> thing?

On second look that sigpending < LONG_MAX check is necessary. When
inc_rlimit_ucounts detects a problem it returns LONG_MAX.

So the check for LONG_MAX is the condensed check to see if there is a
problem in any other levels of the ucount hierarchy.


 \ /
  Last update: 2021-06-29 17:52    [W:0.082 / U:0.108 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site