Re:Red Hat Expecting X.org to “Go into Hard Maintenance Mode...
by DonHopkins on Friday June 28, 2019 @12:04PM
(#20305735)
My point is that ioctl and mmap disprove the "Unix Philosophy" idea that files are one-dimensional streams of characters that are all you need to plug programs together.
[ Parent
| on HN ]
Re:Red Hat Expecting X.org to “Go into Hard Maintenance Mode...
by uep on Friday June 28, 2019 @12:16PM
(#20305891)
Do they though?
Everything as a file is an abstraction, an enormously useful abstraction. The point isn't that it has to behave like a file in every way. At the C level, the fact that open(), read(), write(), or e/poll() behave the similarly is extremely helpful.
I can have a whole suite of functions that do not care what type of file descriptor they hold, but just that those functions behave in a predictable way. Maybe only 10% of my code has to care about the differences between them, instead of 70%.