chiark
/
gitweb
/
~ianmdlvl
/
otter.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8dfbefa
)
apitest: Fix off-by-one error in fd closing
author
Ian Jackson
<ijackson@chiark.greenend.org.uk>
Wed, 5 May 2021 15:08:13 +0000
(16:08 +0100)
committer
Ian Jackson
<ijackson@chiark.greenend.org.uk>
Wed, 5 May 2021 15:08:47 +0000
(16:08 +0100)
This caused very-occasional test lockups...
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
apitest/apitest.rs
patch
|
blob
|
history
diff --git
a/apitest/apitest.rs
b/apitest/apitest.rs
index e16d879a7a6c6f3b6413beb0b842a8b57e801d11..c5fd1da92bf9a6aaa665a742b16f910487593639 100644
(file)
--- a/
apitest/apitest.rs
+++ b/
apitest/apitest.rs
@@
-388,7
+388,7
@@
pub mod cleanup_notify {
for fd in 2.. {
if fd == notify_writing_end { continue }
let r = close(fd);
- if fd >
=
writing_end && matches!(r, Err(Sys(EBADF))) {
+ if fd > writing_end && matches!(r, Err(Sys(EBADF))) {
break;
}
}