Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
dozzie
· 9y ago · 0 comments
...unless something else holds a pointer to the handle you're swapping with.
Comments
[–]
staticassertion
9y ago
This is already a problem if you're removing an item, regardless of whether it's done with swap remove or not.
[–]
toast0
9y ago
For the item you're removing, you are presumably removing it because all handles have been closed. But the item you're potentially swapping with may certainly have open handles.
[–]
staticassertion
9y ago
True.
[–]
blibble
9y ago
kernels don't tend to give userspace raw pointers into kernel memory
[–]
dozzie
OP
9y ago
But kernels tend to give raw pointers to other kernel code.
[–]
blibble
9y ago
a good chunk of the fun in kernel code is maintaining the various layers of self-referential lists and dealing with the cleanup