[commit: ghc] master: rts: Update comment about FreeBSD's unsigned FD_SETSIZE (11c478b)
git at git.haskell.org
git at git.haskell.org
Tue Sep 19 21:55:34 UTC 2017
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/11c478b50e2f56174889fadef3a4e51ed95907d3/ghc
>---------------------------------------------------------------
commit 11c478b50e2f56174889fadef3a4e51ed95907d3
Author: Niklas Hambüchen <mail at nh2.me>
Date: Tue Sep 19 15:11:38 2017 -0400
rts: Update comment about FreeBSD's unsigned FD_SETSIZE
Reviewers: bgamari, austin, erikd, simonmar
Reviewed By: bgamari
Subscribers: rwbarton, thomie
Differential Revision: https://phabricator.haskell.org/D3957
>---------------------------------------------------------------
11c478b50e2f56174889fadef3a4e51ed95907d3
rts/posix/Select.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/rts/posix/Select.c b/rts/posix/Select.c
index 3d3b70b..270e6ff 100644
--- a/rts/posix/Select.c
+++ b/rts/posix/Select.c
@@ -256,9 +256,14 @@ awaitEvent(bool wait)
for(tso = blocked_queue_hd; tso != END_TSO_QUEUE; tso = next) {
next = tso->_link;
- /* On FreeBSD FD_SETSIZE is unsigned. Cast it to signed int
+ /* On older FreeBSDs, FD_SETSIZE is unsigned. Cast it to signed int
* in order to switch off the 'comparison between signed and
* unsigned error message
+ * Newer versions of FreeBSD have switched to unsigned int:
+ * https://github.com/freebsd/freebsd/commit/12ae7f74a071f0439763986026525094a7032dfd
+ * http://fa.freebsd.cvs-all.narkive.com/bCWNHbaC/svn-commit-r265051-head-sys-sys
+ * So the (int) cast should be removed across the code base once
+ * GHC requires a version of FreeBSD that has that change in it.
*/
switch (tso->why_blocked) {
case BlockedOnRead:
More information about the ghc-commits
mailing list