一、What:fcntl是什么?
1. 一句话总结
它是一个对打开的文件进行操作的函数。操作命令是由参数cmd决定的。
2. 详细说说
函数的具体描述为:
#include <unistd.h>
#include <fcntl.h>
int fcntl(int fd, int cmd, ... /* arg */ );
二、Why:为什么需要fcntl,它能干啥?
三、How:fcntl怎么玩
四、参考
fcntl函数手册:http://man7.org/linux/man-pages/man2/fcntl.2.html