please consider the following code:
unsigned long word;
/* read a couple bytes into 'word' from 'fd' */
nr = read (fd, &word, sizeof (unsigned long));
if (nr == -1)
/* error */
This example reads from the file descriptor fd into word.
what does it mean when we say-"reads from the file descriptor
All i understand about file descriptor is that its an int
value returned by open()
system call.Hence the doubt:if fd is not a pointer or an address whats the meaning of saying from file descriptor
Any relevant help would be appreciated.