ORC/ARC async progress (#15370)
* ARC/ORC: fixes memory leak for empty seqs that have a non-zero capacity * async: minor refactorings * it helps to finish a refactoring
This commit is contained in:
parent
cbdda631db
commit
a15d77df7e
3 changed files with 10 additions and 11 deletions
|
|
@ -616,7 +616,7 @@ template withData*[T](s: Selector[T], fd: SocketHandle|int, value,
|
|||
let fdi = int(fd)
|
||||
s.checkFd(fdi)
|
||||
if fdi in s:
|
||||
var value = addr(s.getData(fdi))
|
||||
var value = addr(s.fds[fdi].data)
|
||||
body
|
||||
|
||||
template withData*[T](s: Selector[T], fd: SocketHandle|int, value, body1,
|
||||
|
|
@ -625,7 +625,7 @@ template withData*[T](s: Selector[T], fd: SocketHandle|int, value, body1,
|
|||
let fdi = int(fd)
|
||||
s.checkFd(fdi)
|
||||
if fdi in s:
|
||||
var value = addr(s.getData(fdi))
|
||||
var value = addr(s.fds[fdi].data)
|
||||
body1
|
||||
else:
|
||||
body2
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue