Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

safeioctl may have to contain a redundant switch (or more OOP-style dipatch across multiple functions) on the command code in order to convert the safe style arguments to each specific low level ioctl call. That sort of thing can easily explode in line count. I can see exactly what geofft is talking about.


It's not like your rust safe ioctl wrapper is going to be any less code, though.


Ok - it's true that ioctl has a generic interface (hadn't remembered that). We can think of it as hundreds of functions, not just one. So wrapping ioctl "completely" is correspondingly a lot of work.

However the point was of course to make a safe-land layer which contains the needed functionality. The point was never to have a function "safeioctl" in the first place.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: