$title
diff --git a/lib/posix/posix.nim b/lib/posix/posix.nim
index a18db21500..b29f43eb4c 100644
--- a/lib/posix/posix.nim
+++ b/lib/posix/posix.nim
@@ -109,12 +109,17 @@ type
Dirent* {.importc: "struct dirent",
header: "", final, pure.} = object ## dirent_t struct
d_ino*: Ino ## File serial number.
- when defined(linux) or defined(macosx) or defined(bsd):
+ when defined(dragonfly):
+ # DragonflyBSD doesn't have `d_reclen` field.
+ d_type*: uint8
+ elif defined(linux) or defined(macosx) or defined(freebsd) or
+ defined(netbsd) or defined(openbsd):
d_reclen*: cshort ## Length of this record. (not POSIX)
d_type*: int8 ## Type of file; not supported by all filesystem types.
## (not POSIX)
- when defined(linux) or defined(bsd):
+ when defined(linux) or defined(openbsd):
d_off*: Off ## Not an offset. Value that ``telldir()`` would return.
+
d_name*: array[0..255, char] ## Name of entry.
Tflock* {.importc: "struct flock", final, pure,
diff --git a/lib/pure/concurrency/threadpool.nim b/lib/pure/concurrency/threadpool.nim
index 8cdb83e196..f438a85e76 100644
--- a/lib/pure/concurrency/threadpool.nim
+++ b/lib/pure/concurrency/threadpool.nim
@@ -418,7 +418,7 @@ proc spawn*(call: expr): expr {.magic: "Spawn".}
proc pinnedSpawn*(id: ThreadId; call: expr): expr {.magic: "Spawn".}
## always spawns a new task on the worker thread with ``id``, so that
## the 'call' is **always** executed on
- ## the this thread. 'call' has to be proc call 'p(...)' where 'p'
+ ## the thread. 'call' has to be proc call 'p(...)' where 'p'
## is gcsafe and has a return type that is either 'void' or compatible
## with ``FlowVar[T]``.
diff --git a/tests/async/tioselectors.nim b/tests/async/tioselectors.nim
index 048111d030..5e5a18a1b3 100644
--- a/tests/async/tioselectors.nim
+++ b/tests/async/tioselectors.nim
@@ -508,8 +508,8 @@ else:
freeAddrInfo(aiList)
# for some reason Windows select doesn't return both
# descriptors from first call, so we need to make 2 calls
- discard selector.select(100)
- var rcm = selector.select(100)
+ discard selector.select(1000)
+ var rcm = selector.select(1000)
assert(len(rcm) == 2)
var sockAddress = SockAddr()
@@ -526,7 +526,7 @@ else:
selector.updateHandle(client_socket, {Event.Read})
- var rc2 = selector.select(100)
+ var rc2 = selector.select(1000)
assert(len(rc2) == 1)
var read_count = recv(server2_socket, addr buffer[0], 128, 0)
@@ -595,7 +595,7 @@ else:
proc event_wait_thread(event: SelectEvent) {.thread.} =
var selector = newSelector[int]()
selector.registerEvent(event, 1)
- var rc = selector.select(500)
+ var rc = selector.select(1500)
if len(rc) == 1:
inc(counter)
selector.unregister(event)