Skip to content

Commit 309c5fa

Browse files
xypronpcmoore
authored andcommitted
selinux: fix type mismatch
avc_cache_threshold is of type unsigned int. Do not use a signed new_value in sscanf(page, "%u", &new_value). Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> [PM: subject prefix fix, description cleanup] Signed-off-by: Paul Moore <paul@paul-moore.com>
1 parent 50b8629 commit 309c5fa

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

security/selinux/selinuxfs.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1347,7 +1347,7 @@ static ssize_t sel_write_avc_cache_threshold(struct file *file,
13471347
{
13481348
char *page;
13491349
ssize_t ret;
1350-
int new_value;
1350+
unsigned int new_value;
13511351

13521352
ret = task_has_security(current, SECURITY__SETSECPARAM);
13531353
if (ret)

0 commit comments

Comments
 (0)