projects
/
powerpc.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[PATCH] fix uidhash_lock <-> RCU deadlock
[powerpc.git]
/
security
/
seclvl.c
diff --git
a/security/seclvl.c
b/security/seclvl.c
index
1caac01
..
8529ea6
100644
(file)
--- a/
security/seclvl.c
+++ b/
security/seclvl.c
@@
-368,8
+368,8
@@
static int seclvl_capable(struct task_struct *tsk, int cap)
*/
static int seclvl_settime(struct timespec *tv, struct timezone *tz)
{
*/
static int seclvl_settime(struct timespec *tv, struct timezone *tz)
{
- struct timespec now;
- if (seclvl > 1) {
+ if (tv && seclvl > 1) {
+ struct timespec now;
now = current_kernel_time();
if (tv->tv_sec < now.tv_sec ||
(tv->tv_sec == now.tv_sec && tv->tv_nsec < now.tv_nsec)) {
now = current_kernel_time();
if (tv->tv_sec < now.tv_sec ||
(tv->tv_sec == now.tv_sec && tv->tv_nsec < now.tv_nsec)) {