Skip to content

Instantly share code, notes, and snippets.

@Rachitlohani
Created August 9, 2014 00:22
Show Gist options
  • Save Rachitlohani/5c99fd55784cb41cb909 to your computer and use it in GitHub Desktop.
Save Rachitlohani/5c99fd55784cb41cb909 to your computer and use it in GitHub Desktop.
linux basic sys calls
memset() : This function fills the first n bytes of the memory area pointed to by s with the constant byte c.
fopen() : This function opens the file whose name is the string pointed to by its first argument and associates a stream with it.
getcwd() : This function return a null-terminated string containing an absolute pathname that is the current working directory of the calling process
getuid() : This function returns the real user ID of the calling process
snprintf() : This function produces output according to a format and writes the output to a buffer.
fwrite() : This function is used to write data to a stream
fflush() : This function forces a write of all user space buffered data on to a particular stream
fclose() : This function flushes the associated stream and closes the underlying file descriptor.
system() : This function executes a command
sleep() : This function makes the calling process sleep until specified seconds have elapsed or a signal arrives which is not ignored.
opendir() : This function opens a directory stream
readdir() : This function reads the directory which is opened as a stream
atoi() : This function converts ascii argument to integer.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment