Advanced Programming in the UNIX® Environment
ptg10805159 Section 5.13 Te mporary Files 167 the standardI/O library used on the four platforms described in this book. Be awar ...
ptg10805159 168 StandardI/O Library Chapter 5 Thetmpnamfunction generates a string that is a valid pathname and that does not ma ...
ptg10805159 Section 5.13 Te mporary Files 169 If we execute the program in Figure5.12, we get $./a.out /tmp/fileT0Hsu6 /tmp/file ...
ptg10805159 170 StandardI/O Library Chapter 5 Example The program in Figure5.13 shows how to use (and how not to use) themkstemp ...
ptg10805159 Section 5.14 Memory Streams 171 trying to create second temp file... Segmentation fault The difference in behavior c ...
ptg10805159 172 StandardI/O Library Chapter 5 append, the current file position is set to the first null byte in the buffer.Ifth ...
ptg10805159 Section 5.14 Memory Streams 173 memset(buf, ’c’, BSZ-2); buf[BSZ-2] = ’\0’; buf[BSZ-1] = ’X’; fprintf(fp, "hello, wo ...
ptg10805159 174 StandardI/O Library Chapter 5 The open_memstream function creates a stream that is byte oriented, and the open_w ...
ptg10805159 Chapter 5 Exercises 175 Section 7.8). As with thesfiopackage, ASI attempts to minimize the amount of data copying by ...
ptg10805159 This page intentionally left blank ...
ptg10805159 6 System Data Files and Infor mation 6.1 Introduction AUNIX system requires numerous data files for normal operation ...
ptg10805159 178 System Data Files and Information Chapter 6 struct passwd FreeBSD Linux Mac OS X Solaris Description member POSI ...
ptg10805159 Section 6.2 PasswordFile 179 •Thereare several alternatives to using/dev/nullto prevent a particular user from loggi ...
ptg10805159 180 System Data Files and Information Chapter 6 Both functions return a pointer to apasswdstructurethat the function ...
ptg10805159 Section 6.3 Shadow Passwords 181 The call tosetpwentat the beginning of this function is self-defense: we ensurethat ...
ptg10805159 182 System Data Files and Information Chapter 6 The only two mandatory fields arethe user’s login name and encrypted ...
ptg10805159 Section 6.5 Supplementary Group IDs 183 Like the passwordfile functions, both of these functions normally return poi ...
ptg10805159 184 System Data Files and Information Chapter 6 #include <unistd.h> int getgroups(intgidsetsize,gid_tgrouplist ...
ptg10805159 Section 6.7 Other Data Files 185 FreeBSD Linux Mac OS X Solaris Information 8.0 3.2.0 10.6.8 10 account information ...
ptg10805159 186 System Data Files and Information Chapter 6 The general principle is that every data file has at least three fun ...
«
6
7
8
9
10
11
12
13
14
15
»
Free download pdf