函数原型:int open(const char *path,int oflags,mode_t mode);
返回打开文件的描述符,失败返回-1;
参数:
const char * path: 打开文件的路径(文件名)
int oflags: 打开文件的方式(具有什么样操作方式)
mode_t mode:当以创建方式(O_CREAT)打开文件时,设置文件的权限与mask取and
函数原型:int open(const char *path,int oflags,mode_t mode);
返回打开文件的描述符,失败返回-1;
参数:
const char * path: 打开文件的路径(文件名)
int oflags: 打开文件的方式(具有什么样操作方式)
mode_t mode:当以创建方式(O_CREAT)打开文件时,设置文件的权限与mask取and
转载于:https://www.cnblogs.com/hust2012/archive/2012/12/06/2805521.html