blob: 0a16dcb6be662c14ea3a98fd7d41d98c7fe3629d [file] [log] [blame]
Kun Yi73380f62019-01-09 13:35:28 -08001#include "sys.hpp"
2
3#include <fcntl.h>
4#include <unistd.h>
5
6namespace binstore
7{
8
9namespace internal
10{
11
12int SysImpl::open(const char* pathname, int flags) const
13{
14 return ::open(pathname, flags);
15}
16
17int SysImpl::close(int fd) const
18{
19 return ::close(fd);
20}
21
22off_t SysImpl::lseek(int fd, off_t offset, int whence) const
23{
24 return ::lseek(fd, offset, whence);
25}
26
27ssize_t SysImpl::read(int fd, void* buf, size_t count) const
28{
29 return ::read(fd, buf, count);
30}
31
32ssize_t SysImpl::write(int fd, const void* buf, size_t count) const
33{
34 return ::write(fd, buf, count);
35}
36
37SysImpl sys_impl;
38
39} // namespace internal
40
41} // namespace binstore