diff options
| author | Mark Brown <broonie@kernel.org> | 2026-08-07 17:10:41 +0100 |
|---|---|---|
| committer | Mark Brown <broonie@kernel.org> | 2026-08-07 17:10:41 +0100 |
| commit | f1a9521fd437d63272c7faae715a8874efcb3984 (patch) | |
| tree | f09fb233968a63fae172504318ecf5b7cd3b4eee /drivers/tty/vt/vt_ioctl.c | |
| parent | 2d5de9f0dec1876c0f0aeaa5a7205663381e226d (diff) | |
| parent | 8b0b29fdcb47907ae0296b8fe829e918e05e300f (diff) | |
| download | linux-next-f1a9521fd437d63272c7faae715a8874efcb3984.tar.gz linux-next-f1a9521fd437d63272c7faae715a8874efcb3984.zip | |
Merge branch 'tty-next' of ssh://git@gitolite.kernel.org/pub/scm/linux/kernel/git/gregkh/tty.git
Diffstat (limited to 'drivers/tty/vt/vt_ioctl.c')
| -rw-r--r-- | drivers/tty/vt/vt_ioctl.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/tty/vt/vt_ioctl.c b/drivers/tty/vt/vt_ioctl.c index deb3b3f93461..ecefe4a666f2 100644 --- a/drivers/tty/vt/vt_ioctl.c +++ b/drivers/tty/vt/vt_ioctl.c @@ -598,6 +598,8 @@ static int vt_setactivate(struct vt_setactivate __user *sa) return -EFAULT; if (vsa.console == 0 || vsa.console > MAX_NR_CONSOLES) return -ENXIO; + if (vsa.mode.mode != VT_AUTO && vsa.mode.mode != VT_PROCESS) + return -EINVAL; vsa.console--; vsa.console = array_index_nospec(vsa.console, MAX_NR_CONSOLES); |
