The Open Source Swiss Army Knife

/code/c/unix_c/filedes/
/code/c/unix_c/filedes/ + sub-categories
http://www.sirfsup.com/
web directory content
    
      

Not logged in
Chat Register Login
return to:  http:/www.sirfsup.com      /code   /c   /unix_c   /filedes 
sub-categories and articles

                                                  
dirdup2 add
   --->create new sub-category


declaration.c
creaetes a file, writes to it, closes that file

// creaetes a file, writes to it, closes that file

fdes_IO.htm
unix open pipe fdopen fopen calls


file_manipulation.htm
functions for file manipulation: ioctl fcntl fstat

see here

filedes_io.c
from Linux Programming: open,read,fd,flock

#include <sys/types.h>

fopen.c
returns a file pointer which becomes the argument to fgetc and fclose
does not read from STDIN but opens a hard-coded file

/* see <a href="http://www.sirfsup.com/languages/c/ISO_c_basics/standardIO/fopen.c.html">here</a>   */

inodes.htm
add

dir entry contains a number and an inode; that inode is a reference to a table -- the inode is both that hnumber and the data structure stored on disk. The OS keeps in memory all the inodes currently in use. The inode contains the about the file (owner, group owner, various times, where the file is stored on the disk, a reference to blocks, a double-indirect block, a triple-indirect block, count of number of hard links to the inode) except the name of the file.

inode and all files associated with the inode are deleted when the count in the inode is == 0


open.c
simplest of open() examples

#include <stdio.h>

open.htm
describes open()

linux programming in C

  • open() int open(const char *pathname, int flags)
    int open(const char *pathname, int flags, mode_t mode)

pipes.txt
add

try looking in http://www.sirfsup.com/languages/c/unix_c/pipes/pipes.txt

ssh_source.c
openssh code: dup2 stdin redirect c unix linux

 /*
   --->upload your article


User submitted category site links


(None)

-->submit a page from your site dealing with filedes to the sirfsup! web directory for listing

return to top