Page MenuHomeFreeBSD

D60800.id190099.diff
No OneTemporary

D60800.id190099.diff

diff --git a/tests/sys/sound/mmap.c b/tests/sys/sound/mmap.c
--- a/tests/sys/sound/mmap.c
+++ b/tests/sys/sound/mmap.c
@@ -40,9 +40,7 @@
buf = mmap(NULL, len, PROT_READ | PROT_WRITE, MAP_SHARED, fd, off);
ATF_REQUIRE_MSG(buf == MAP_FAILED, FMT_ERR("mmap"));
- munmap(buf, len);
-
- close(fd);
+ ATF_REQUIRE(close(fd) == 0);
}
/*
@@ -124,9 +122,7 @@
fd, 0);
ATF_REQUIRE_MSG(buf == MAP_FAILED, FMT_ERR("mmap"));
- munmap(buf, len);
-
- close(fd);
+ ATF_REQUIRE(close(fd) == 0);
}
/*
diff --git a/tests/sys/sound/polling.c b/tests/sys/sound/polling.c
--- a/tests/sys/sound/polling.c
+++ b/tests/sys/sound/polling.c
@@ -98,7 +98,7 @@
ATF_REQUIRE_MSG(read(fd, buf, sizeof(buf)) > 0, FMT_ERR("read"));
EV_SET(&ev, fd, EVFILT_READ, EV_DELETE, 0, 0, 0);
- close(kq);
+ ATF_REQUIRE(close(kq) == 0);
kq = kqueue();
ATF_REQUIRE_MSG(kq >= 0, FMT_ERR("kqueue"));
@@ -113,9 +113,9 @@
ATF_REQUIRE_MSG(write(fd, buf, sizeof(buf)) > 0, FMT_ERR("write"));
EV_SET(&ev, fd, EVFILT_WRITE, EV_DELETE, 0, 0, 0);
- close(kq);
+ ATF_REQUIRE(close(kq) == 0);
- close(fd);
+ ATF_REQUIRE(close(fd) == 0);
}
ATF_TC(poll_poll);
@@ -154,7 +154,7 @@
wr = true;
}
}
- close(fd);
+ ATF_REQUIRE(close(fd) == 0);
}
ATF_TC(poll_select);
@@ -192,7 +192,7 @@
wr = true;
}
}
- close(fd);
+ ATF_REQUIRE(close(fd) == 0);
}
ATF_TP_ADD_TCS(tp)
diff --git a/tests/sys/sound/sndstat.c b/tests/sys/sound/sndstat.c
--- a/tests/sys/sound/sndstat.c
+++ b/tests/sys/sound/sndstat.c
@@ -196,7 +196,7 @@
free(arg.buf);
nvlist_destroy(nvl);
- close(fd);
+ ATF_REQUIRE(close(fd) == 0);
}
#define UDEV_PROVIDER "sndstat_udev"
@@ -374,7 +374,7 @@
free(arg.buf);
nvlist_destroy(nvl);
- close(fd);
+ ATF_REQUIRE(close(fd) == 0);
}
ATF_TP_ADD_TCS(tp)

File Metadata

Mime Type
text/plain
Expires
Sun, Oct 18, 3:47 PM (2 h, 15 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
40998636
Default Alt Text
D60800.id190099.diff (1 KB)

Event Timeline