21 the socket will not be closed until both the

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Web servers in Section 12.7. The st mode member encodes both the file type and the file protection bits. The st size member contains the file size in bytes. The meaning of the other members is beyond our scope. statbuf.h (included by sys/stat.h) /* file info returned by the stat struct stat dev_t st_dev; /* ino_t st_ino; /* mode_t st_mode; /* nlink_t st_nlink; /* uid_t st_uid; /* gid_t st_gid; /* dev_t st_rdev; /* off_t st_size; /* unsigned long st_blksize; /* unsigned long st_blocks; /* time_t st_atime; /* time_t st_mtime; /* time_t st_ctime; /* ; function */ device */ inode */ protection and file type */ number of hard links */ user ID of owner */ group ID of owner */ device type (if inode device) */ total size, in bytes */ blocksize for filesystem I/O */ number of blocks allocated */ time of last access */ time of last modification */ time of last change */ statbuf.h (included by sys/stat.h) Figure 12.17: The stat structure. A Unix system recognizes a number of different file types. For example, a regular file contains some sort of binary or text data. To the kernel there is no diffe...
View Full Document

This note was uploaded on 09/02/2010 for the course ELECTRICAL 360 taught by Professor Schultz during the Spring '10 term at BYU.

Ask a homework question - tutors are online