lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-id: <20170705172444.7853-1-k.opasiak@samsung.com>
Date:   Wed, 05 Jul 2017 19:24:44 +0200
From:   Krzysztof Opasiak <k.opasiak@...sung.com>
To:     gregkh@...uxfoundation.org, arve@...roid.com, riandrews@...roid.com
Cc:     devel@...verdev.osuosl.org, linux-kernel@...r.kernel.org,
        Krzysztof Opasiak <k.opasiak@...sung.com>
Subject: [PATCH 1/4] android: binder: Use dedicated helper to access rlimit
 value

Use rlimit() helper instead of manually writing whole
chain from current task to rlim_cur

Signed-off-by: Krzysztof Opasiak <k.opasiak@...sung.com>
---
 drivers/android/binder.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/android/binder.c b/drivers/android/binder.c
index aae4d8d4be36..d802384ccdd3 100644
--- a/drivers/android/binder.c
+++ b/drivers/android/binder.c
@@ -472,7 +472,7 @@ static void binder_set_nice(long nice)
 		set_user_nice(current, nice);
 		return;
 	}
-	min_nice = rlimit_to_nice(current->signal->rlim[RLIMIT_NICE].rlim_cur);
+	min_nice = rlimit_to_nice(rlimit(RLIMIT_NICE));
 	binder_debug(BINDER_DEBUG_PRIORITY_CAP,
 		     "%d: nice value %ld not allowed use %ld instead\n",
 		      current->pid, nice, min_nice);
-- 
2.9.3

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ