r:O_RDONLY
r+:O_RDWR
w:O_WRONLY|O_TRUNC|O_CREAT
w+:O_RDWR|O_TRUNC|O_CREAT
a:O_WRONLY|O_APPEND|O_CREAT
a+:O_RDWR|O_APPEND|O_CREAT
r:O_RDONLY
r+:O_RDWR
w:O_WRONLY|O_TRUNC|O_CREAT
w+:O_RDWR|O_TRUNC|O_CREAT
a:O_WRONLY|O_APPEND|O_CREAT
a+:O_RDWR|O_APPEND|O_CREAT