diff options
| author | Konstantin Belousov <kib@FreeBSD.org> | 2026-06-24 22:27:45 +0000 |
|---|---|---|
| committer | Konstantin Belousov <kib@FreeBSD.org> | 2026-06-24 22:31:02 +0000 |
| commit | 3377f38cfe284a8490b49611614aae3a2bea78e4 (patch) | |
| tree | e12204400ace381362b67326da8cb1e34e1a91e1 | |
| parent | e63fbcc69402d4a1e8681a95710f0ec01a6837b4 (diff) | |
uiomove_fault(): initialize save with ~0 when no flags are cleared
Reported by: markj
Fixes: 4c4195700249 ("sys: use curthread_pflags_set/restore to manage TDP_DEADLKTREAT for uio")
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
| -rw-r--r-- | sys/kern/subr_uio.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/kern/subr_uio.c b/sys/kern/subr_uio.c index 7e492d8aa705..e2059d3813d4 100644 --- a/sys/kern/subr_uio.c +++ b/sys/kern/subr_uio.c @@ -264,7 +264,7 @@ uiomove_faultflag(void *cp, int n, struct uio *uio, int nofault) save = curthread_pflags_set(newflags); } else { KASSERT(nofault == 0, ("uiomove: nofault")); - save = 0; + save = ~0; } while (n > 0 && uio->uio_resid) { |
