Commit 94178625 authored by Ramon Nou's avatar Ramon Nou
Browse files

stat functions

more functions
add openat
parent 9bf297b4
Loading
Loading
Loading
Loading
+21 −7
Original line number Diff line number Diff line
@@ -84,17 +84,17 @@ off64_t
dlsym_lseek64(int fd, off64_t offset, int whence);

int
dlsym_fstat(int ver, int fd, struct stat* buf);
dlsym_fstat(int fd, struct stat* buf);
int
dlsym_fxstat64(int ver, int fd, struct stat64* buf);
dlsym_fxstat64(int fd, struct stat64* buf);
int
dlsym_stat(int ver, const char* path, struct stat* buf);
dlsym_stat(const char* path, struct stat* buf);
int
dlsym_lstat(int ver, const char* path, struct stat* buf);
dlsym_lstat(const char* path, struct stat* buf);
int
dlsym_lxstat64(int ver, const char* path, struct stat64* buf);
dlsym_lxstat64(const char* path, struct stat64* buf);
int
dlsym_xstat64(int ver, const char* path, struct stat64* buf);
dlsym_xstat64(const char* path, struct stat64* buf);
int
dlsym_fstatat(int dfd, const char* path, struct stat* buf, int flags);
int
@@ -189,6 +189,11 @@ dlsym_fsync(int fd);
int
dlsym_flock(int fd, int operation);

// Manager API

char*
dlsym_realpath(const char* path, char* resolved_path);


// Memory API
void*
@@ -199,6 +204,10 @@ int
open64(const char* path, int flags, ...);
int
open(const char* path, int flags, ...);
//openat 
int openat (int __fd, const char *__file, int __oflag, ...);


int
close(int fd);
int
@@ -218,7 +227,12 @@ mkdir(const char* path, mode_t mode);

int
rmdir(const char* path) noexcept;

int
dup(int oldfd) __THROW __wur;
int
dup2(int oldfd, int newfd) __THROW;
int
dup3(int oldfd, int newfd, int flags) __THROW;
ssize_t
pread(int fd, void* buf, size_t count, off_t offset);
ssize_t
+9 −0
Original line number Diff line number Diff line
@@ -76,6 +76,15 @@ gkfs_stat(const std::string& path, struct stat* buf, bool follow_links = true);
int
gkfs_remove(const std::string& path);

int
gkfs_dup(const int oldfd);

int
gkfs_dup2(const int oldfd, const int newfd);

int
gkfs_access(const std::string& path, const int mask, bool follow_links);

std::vector<std::string>
gkfs_get_file_list(const std::string& path);
} // namespace syscall
+868 −52

File changed.

Preview size limit exceeded, changes collapsed.