I\'m learning about file descriptors and I wrote this code:
#include #include #include #include
I think O_CREAT alone is not enough. Try adding O_WRONLY as flag to the open command.
O_CREAT
O_WRONLY