diff options
author | bde <bde@FreeBSD.org> | 2002-02-16 07:07:54 +0000 |
---|---|---|
committer | bde <bde@FreeBSD.org> | 2002-02-16 07:07:54 +0000 |
commit | 20dfbd36b691a01165ad6fdce5b807b60aa5b695 (patch) | |
tree | 492c4c6efcc83c9103854614149c97bad7d4ce12 /sys/i386 | |
parent | 99e8a64ee46b9dca21a173793db2dbafbf3fd56e (diff) | |
download | FreeBSD-src-20dfbd36b691a01165ad6fdce5b807b60aa5b695.zip FreeBSD-src-20dfbd36b691a01165ad6fdce5b807b60aa5b695.tar.gz |
Don't leave garbage in parts of fpregs in the fxsr case. All callers
(procfs and ptrace) supply kernel stack garbage, so kernel context was
leaked to userland.
Reviewed by: des
Diffstat (limited to 'sys/i386')
-rw-r--r-- | sys/i386/i386/machdep.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/i386/i386/machdep.c b/sys/i386/i386/machdep.c index c0ce595..c6bdb57 100644 --- a/sys/i386/i386/machdep.c +++ b/sys/i386/i386/machdep.c @@ -2018,6 +2018,8 @@ fill_fpregs_xmm(sv_xmm, sv_87) register struct envxmm *penv_xmm = &sv_xmm->sv_env; int i; + bzero(sv_87, sizeof(*sv_87)); + /* FPU control/status */ penv_87->en_cw = penv_xmm->en_cw; penv_87->en_sw = penv_xmm->en_sw; |