-
Notifications
You must be signed in to change notification settings - Fork 17
Expand file tree
/
Copy pathunistd.h
More file actions
28 lines (22 loc) · 698 Bytes
/
unistd.h
File metadata and controls
28 lines (22 loc) · 698 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
// unistd.h
// Copyright (C) 2022 iProgramInCpp
// The NanoShell Standard C Library
#ifndef _UNISTD_H
#define _UNISTD_H
#include <nanoshell/unistd_types.h>
// POSIX file access functions
int open (const char *pfn, int oflag);
int close (int fd);
int read (int fd, void* buf, unsigned int nbyte);
int write (int fd, const void* buf, unsigned int nbyte);
int lseek (int fd, int offset, int whence);
int tellf (int fd);
int tellsz(int fd); // not standard
int chdir (const char *pfn);
int fchdir(int fd);
int unlink(const char *pfn);
char* getcwd(char* buf, size_t sz);
int usleep(int microseconds);
// NanoShell specifics
const char* FiGetCwd();
#endif//_UNISTD_H