Appearance
stat.h
#include "types.h"
TIP
文件类型定义
#define T_DIR 1
#define T_FILE 2
#define T_DEVICE 3
TIP
stat 结构体,用于描述一个文件的元数据信息 这个结构体的信息可以通过 stat 或 fstat 系统调用获取
struct stat {
int dev;
uint ino;
short type;
short nlink;
uint64 size;
};