mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 18:51:56 -04:00
security: replace strict_strto*() with kstrto*()
The usage of strict_strto*() is not preferred, because strict_strto*() is obsolete. Thus, kstrto*() should be used. Signed-off-by: Jingoo Han <[email protected]> Signed-off-by: James Morris <[email protected]>
This commit is contained in:
parent
923b49ff69
commit
29707b206c
7 changed files with 12 additions and 12 deletions
|
|
@ -520,7 +520,7 @@ static int ima_parse_rule(char *rule, struct ima_rule_entry *entry)
|
|||
break;
|
||||
}
|
||||
|
||||
result = strict_strtoul(args[0].from, 16,
|
||||
result = kstrtoul(args[0].from, 16,
|
||||
&entry->fsmagic);
|
||||
if (!result)
|
||||
entry->flags |= IMA_FSMAGIC;
|
||||
|
|
@ -547,7 +547,7 @@ static int ima_parse_rule(char *rule, struct ima_rule_entry *entry)
|
|||
break;
|
||||
}
|
||||
|
||||
result = strict_strtoul(args[0].from, 10, &lnum);
|
||||
result = kstrtoul(args[0].from, 10, &lnum);
|
||||
if (!result) {
|
||||
entry->uid = make_kuid(current_user_ns(), (uid_t)lnum);
|
||||
if (!uid_valid(entry->uid) || (((uid_t)lnum) != lnum))
|
||||
|
|
@ -564,7 +564,7 @@ static int ima_parse_rule(char *rule, struct ima_rule_entry *entry)
|
|||
break;
|
||||
}
|
||||
|
||||
result = strict_strtoul(args[0].from, 10, &lnum);
|
||||
result = kstrtoul(args[0].from, 10, &lnum);
|
||||
if (!result) {
|
||||
entry->fowner = make_kuid(current_user_ns(), (uid_t)lnum);
|
||||
if (!uid_valid(entry->fowner) || (((uid_t)lnum) != lnum))
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ static int __init integrity_audit_setup(char *str)
|
|||
{
|
||||
unsigned long audit;
|
||||
|
||||
if (!strict_strtoul(str, 0, &audit))
|
||||
if (!kstrtoul(str, 0, &audit))
|
||||
integrity_audit_info = audit ? 1 : 0;
|
||||
return 1;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue