#include #include #include #include int main() { int fd; char * myfifo = "/tmp/myfifo"; /* create the FIFO (named pipe) */ mkfifo(myfifo, 0666); /* write "Hi" to the FIFO */ fd = open(myfifo, O_WRONLY); write(fd, "COSC330 is cool!", sizeof("COSC330 is cool!")); close(fd); /* remove the FIFO */ unlink(myfifo); return 0; }