martinpitt / umockdev

Mock hardware devices for creating unit tests and bug reporting
https://launchpad.net/umockdev
GNU Lesser General Public License v2.1
308 stars 55 forks source link

clear() does not detach ioctl handlers #194

Open benzea opened 2 years ago

benzea commented 2 years ago

OK, not sure about this one, so opening a bug.

Should clear implicitly detach all ioctl handlers, or should people still need to detach them explicitly?

Note that there is an internal hash table, to allow detaching. And this hash table might get autodated with clear() as the device is not removed there. But then, what happens if the socket/device is removed from the disk in some other way?