mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-23 08:00:20 +00:00
0dc9af5f7e
Also run it across the whole tree to get everything using the One True Style. We don't yet run this in an automated fashion as it's a little slow, but there is a snippet to do so in makeall.sh.
26 lines
856 B
C
26 lines
856 B
C
#pragma once
|
|
|
|
#include <fcntl.h>
|
|
#include <sys/cdefs.h>
|
|
#include <sys/types.h>
|
|
|
|
__BEGIN_DECLS
|
|
|
|
#define S_ISDIR(m) (((m)&S_IFMT) == S_IFDIR)
|
|
#define S_ISCHR(m) (((m)&S_IFMT) == S_IFCHR)
|
|
#define S_ISBLK(m) (((m)&S_IFMT) == S_IFBLK)
|
|
#define S_ISREG(m) (((m)&S_IFMT) == S_IFREG)
|
|
#define S_ISFIFO(m) (((m)&S_IFMT) == S_IFIFO)
|
|
#define S_ISLNK(m) (((m)&S_IFMT) == S_IFLNK)
|
|
#define S_ISSOCK(m) (((m)&S_IFMT) == S_IFSOCK)
|
|
|
|
mode_t umask(mode_t);
|
|
int chmod(const char* pathname, mode_t);
|
|
int fchmod(int fd, mode_t);
|
|
int mkdir(const char* pathname, mode_t);
|
|
|
|
inline dev_t makedev(unsigned int major, unsigned int minor) { return (minor & 0xffu) | (major << 8u) | ((minor & ~0xffu) << 12u); }
|
|
inline unsigned int major(dev_t dev) { return (dev & 0xfff00u) >> 8u; }
|
|
inline unsigned int minor(dev_t dev) { return (dev & 0xffu) | ((dev >> 12u) & 0xfff00u); }
|
|
|
|
__END_DECLS
|