This page lists errata for The Linux Programming Interface. (For information about changes to the kernel-user-space and glibc APIs since TLPI was published, see the API changes page. For information about changes to the source code examples associated with book, see the source code CHANGES page.)
In general, if you make an error report I'll list your name against the report, and even link to a home page or similar if you like. If you don't want your name to appear against the error report, please let me know at the time that you make the report.
You may also want to look at this frequently asked question.
Order errata list by: page number, print run, report date, or category
Last updated: 2024-10-15; last error report: 2024-09-13
This version of the errata page lists fixes according to the print run of the book in which they first appeared.
Below, the page number column uses the following coding for errors:
Color code | Explanation |
---|---|
Code fix | A significant fix to a piece of code |
Minor code fix | A minor fix to a piece of code; generally the problem and its solution should be obvious on an attentive reading of the text, or there is a syntax error in a code snippet that would be detected during compilation |
Technical fix | A significant fix to a technical point explained in the text |
Minor technical fix | A minor fix to a technical point explained in the text (typically a correction to a minor or obvious technical error or imprecision in the text) |
Clarification | A significant clarification to an explanation in the text |
Minor clarification | A minor clarification to an explanation in the text (the overall meaning of the text isn't changed, but a minor detail is added or improved) |
Update | This is a note on information that is new since the book was published (normally information relating to a kernel or glibc change); there won't be a change to the text |
Typo | A fix to a minor typographical or grammar error, or a replacement of an (obviously) incorrect word |
Use the following links to jump to:
To determine which printing of the book you have, look at the page containing the copyright notice (one of the pages right at the start of the book, before the table of contents). Near the top of the page, just below the copyright notice, is a line of numbers. The lowest ordinal number that you can see in this list indicates the print run that produced your copy of the book.
The following fixes and improvements will be applied in the next printing.
[No errata]
The following points are notes to the text, rather than fixes; there are no corresponding changes in the text of any print run.
Page | Fix | Reported |
9 |
As a consequence of the (July 2011) renumbering of the Linux kernel series from 2.6.x to 3.x and then 4.x, 5.x, and (most recently) 6.x, the discussion of kernel numbering on this page is now out-of-date. However, all that has changed is that the numbering scheme has been simplified (replacing an invariant 2.6 with 3 and, subsequently, 4, 5, and 6); the kernel development model remains unchanged. As Linus Torvalds noted of the 3.0 release, there is otherwise nothing special about the release (i.e., no changes more significant than those in Linux 2.6.39 and each of the preceding 2.6.x releases). In the bulleted list at the top of the page, each of the instances of 2.6.z could simply be replaced by 6.z and the description on this page would still be accurate for the current kernel development model. Explanation:
|
2011-07-29 |
9 |
The small-font note at the bottom of the page states "At the time of writing, the 2.4 stable Linux kernel is still supported…" This has now ceased to be true: in April 2012, Willy Tarreau, the Linux 2.4 maintainer, noted that the 2.4 kernel series has now reached end-of-life. |
2012-04-10 |
16 |
As a follow-on to the discussion in Section 1.3.5, note that the Austin group published Technical Corrigendum Number 1 for POSIX.1-2008/SUSv4, in 2013, Technical Corrigendum Number 2 in 2016. The standard can be found online at http://www.unix.org/version4/. Explanation: (This note was updated on 14 October 2017.) |
2014-01-17 |
44 |
In the list item "5" (toward the bottom of the page), change: In response to the trap to location 0x80, the kernel invokes its system_call() routine (located in the assembler file arch/x86/kernel/entry.S) to handle the trap. to: In response to the trap to location 0x80, the kernel invokes its system_call() routine to handle the trap. Explanation:
Reported by Alex Colomar. |
2021-04-05 |
46 |
Because of ongoing changes in the kernel and in the GNU C library, all of the pathnames mentioned in Figure 3-1 are no longer accurate. Since such changes are likely to be ongoing in the future, I won't make further updates in this figure, and will just note that the pathnames in the upper right, lower left, and lower right boxes are all nowadays out of date. Explanation:
Reported by Alex Colomar. |
2021-04-05 |
62 |
The description of the _BSD_SOURCE feature test macro about one third of the way down this page says that it causes BSD definitions to be favored in a few cases where standards conflict. Starting with glibc 2.19, _BSD_SOURCE no longer has this effect. |
2014-01-06 |
62 |
Starting with version 2.19, glibc adds a new feature test macro, _DEFAULT_SOURCE. Defining this macro provides an effect similar to the feature test macros that are defined by default—that is, _BSD_SOURCE, _SVID_SOURCE, and _POSIX_C_SOURCE=200809. This macro can be defined to ensure that the "default" definitions are provided even when the defaults would otherwise be disabled, as happens when individual macros are explicitly defined, or the compiler is invoked in one of its "standard" modes (e.g., cc -std=c99). |
2014-01-06 |
62 |
In glibc 2.20 and later, _BSD_SOURCE and _SVID_SOURCE are deprecated. They are redefined to have the same meaning as _DEFAULT_SOURCE, and thus continue to expose all of the definitions that they exposed earlier. However, the use of these macros now produces a warning, unless _DEFAULT_SOURCE is also defined. This means that all function prototype boxes in TLPI that show _BSD_SOURCE or _SVID_SOURCE as being required should instead show _DEFAULT_SOURCE. However, that change will be left to a future edition of TLPI. In the meantime, a workaround fix to the makefiles has been added to the code in the source distribution so that now all code is compiled with _DEFAULT_SOURCE defined. Note also that starting with release 4.05 (March 2016), the Linux manual pages provide up-to-date documentation of the feature test macro requirements since glibc 2.20. |
2014-03-12 |
72 |
Some further explanation may be useful for readers that try running a command similar to this command shown in the shell session near the top of the page: $ ./copy /dev/pts/16 /dev/tty In this case, /dev/pts/16 is a pseudoterminal device that is being used as the input file for the copy program. (You can discover the name of the pseudoterminal being employed in a terminal window by running the tty command.) If trying this example, you may see results that are puzzling until various topics are covered later in the book. In particular, if, as is likely the case, a shell is running in the foreground of the source device, then the following points mean that some of the text that you type on the source device may not be copied to /dev/tty:
One way to avoid this confusing behavior is to run a command such as sleep 1000 on the source device. This will cause the shell to set the terminal to canonical mode (input available a line at a time) and place itself in the background. This will stop the shell competing for input, and will make all input typed on the source device available (a line at a time) to the copy program. Reported by Henri van de Water. |
2015-03-12 |
74 |
Since Linux 2.6.39, the open() system call supports a new file creation flag, O_PATH, that can be used to obtain a file descriptor with specific, limited uses. The returned file descriptor can be closed, duplicated, or passed via a UNIX domain socket (see Section 61.13.3); the file descriptor can't be read from or written to. O_PATH can be used to obtain file descriptors for symbolic links. O_PATH file descriptors are provided for use as the directory file descriptor argument in the *at() system calls (see Section 18.11). |
2011-06-26 |
82 |
This note is also relevant for the discussion of file holes on page 83. Linux 3.1 adds two new operations for the lseek() system call: SEEK_HOLE and SEEK_DATA. These operations can be used to determine the start and end of holes in a file. SEEK_HOLE seeks to the offset of the next file hole whose location is greater than or equal to the current file offset. SEEK_DATA seeks to the offset of the next non-hole region whose location is greater than or equal to the current file offset. |
2011-07-29 |
83 |
Linux 2.6.38 added FALLOC_FL_PUNCH_HOLE, a new operation for the fallocate() system call. This operation creates a hole in a file in the byte range indicated by the system call's offset and len arguments. (The file data in the specified range is lost.) Among the file systems that already support this operation are XFS and (since Linux 3.0) ext4. Btrfs is capable of supporting the operation, and support is likely to be added in the future. |
2011-06-30 |
100 |
The details described in the second paragraph (starting "However, the glibc wrapper functions for readv() and writev()) in the small-font note at the top of the page have no longer been true for quite a while. Since glibc 2.10, if the wrapper functions for readv() and writev() detect that the kernel version is 2.6.18 or later, they always only invoke the raw system calls. And since glibc 2.20, where the minimum Linux kernel version required by the library is 2.6.32, the wrapper functions always just directly invoke the system calls. For further details, see the preadv(2) manual page. |
2015-01-20 |
137 |
Regarding the discussion on pages 135-137 of longjmp() clobbering variables (and especially the example shown a bit more than half way down page 137), things seem to have changed a little since the book was published. In more recent versions of gcc, the "warning: variable `nvar' might be clobbered by `longjmp' or `vfork'" warning is generated in cases where compiler optimization is disabled, and is not generated when optimization is enabled. Presumably, gcc is warning about the cases where clobbering can occur, and in more recent versions of the compiler, that is the case when optimization is disabled. I've yet to determine in which gcc version the behavior changed, or the rationale for the change. Reported by Henri van de Water. |
2015-03-24 |
165 |
About half-way down the page, there is the following piece of code in Listing 8-2 (users_groups/check_password.c): spwd = getspnam(username); if (spwd == NULL && errno == EACCES) fatal("no permission to read shadow password file"); if (spwd != NULL) /* If there is a shadow password record */ pwd->pw_passwd = spwd->sp_pwdp; /* Use the shadow password */ However, depending on your system configuration, getspnam() may not return the error EACCES if the user doesn't have permission to read the shadow password file. In particular, it may be that in your system's /etc/nsswitch.conf file, you see systemd listed: shadow: files systemd (It is likely that you will see this if you have a Debian-based or Arch-based distribution.) In the case where the Name Server Switch falls back to using systemd, and systemd determines that the user does not have sufficient permission to access the shadow password file, the getspnam() call simply returns NULL without setting errno. In that case, the program will fall through to a later check that prints a message that the password is incorrect: authOk = strcmp(encrypted, pwd->pw_passwd) == 0; if (!authOk) { printf("Incorrect password\n"); exit(EXIT_FAILURE); } |
2024-01-09 |
224 |
In the first paragraph of this page, I refer to /proc as a "virtual file system". It would have been worth noting two points in relation to this term:
However, there isn't sufficient space on the page to add this information. Reported by Bill McConnaughey. |
2011-07-18 |
241 |
Since Linux 2.6.39, the new syncfs() system call can be used to flush all kernel buffers containing updated file information for a specified file system (i.e., a per-file-system sync()). The file system is specified using a file descriptor that refers to an open file in the file system. |
2011-06-26 |
241 |
The discussion of the pdflush kernel thread in the two small-font paragraphs near the bottom of this page is obsolete. (It was already obsolete at the time the book went to press, when kernel 2.6.35 was the current kernel version, but I missed the change.) Although the general principles described in the text remain accurate, in Linux 2.6.32 the pdflush was replaced by the so-called per-BDI flush mechanism, described in the LWN.net article, "Flushing out pdflush". |
2012-08-21 |
301 |
The example shell session at the top of this page is technically correct, but could have been better chosen. As explained earlier in Section 15.4.5, the sticky bit no longer serves any purpose for regular (executable) files, but it does serve a purpose for directories. Therefore, a better example would have been to demonstrate manipulating the sticky bit of a directory, rather than a file. Reported by Simon Durrant. |
2011-08-23 |
312 |
The first bullet point on this page notes that various filesystems require that the filesystem be mounted with the mount –o user_xattr option in order to employ user EAs. Among the listed filesystems is ext4. However, since Linux 2.6.39, this option is no longer required for ext4: user EAs are enabled by default. |
2015-01-22 |
314 |
The second bullet point on this page notes that on JFS there is a 128 kB limit on the total bytes used by the names and values of all EAs on a file. More recent kernels have removed this limit, so that it is possible to create much larger sets of EAs on a file. I haven't determined what the limiting factors are now, or when the changes occurred, but on a Linux 3.0 system I was able to attach 4 MB of EAs to a file on JFS. Reported by Junjiro Okajima. |
2012-07-06 |
319 |
The second paragraph of the small-font note on this page notes that various filesystems require that the filesystem be mounted with the mount –o acl option in order to user ACLs. Among the listed filesystems is ext4. However, since Linux 2.6.39, this option is no longer required for ext4: ACLs are enabled by default. |
2015-01-22 |
344 |
This note relates to the section headed Interpretation of symbolic links by system calls. Linux 3.6 added some restrictions on the operation of symbolic links; these restrictions can cause system calls that dereference symbolic links to fail with the error EACCES if they are violated. The goal of these restrictions is to prevent a class of security issues caused by time-of-check, time-of-use races when accessing symbolic links. For more information, see this LWN.net article and the documentation of /proc/sys/fs/protected_symlinks in the proc(5) man page. |
2012-10-15 |
345 |
Linux 3.6 added some restrictions on the creation of hard links; these restrictions can cause link() to return with an EPERM error if they are violated. The goal of the changes is to prevent a class of security issues caused by hard-link-based time-of-check, time-of-use races, most commonly seen in world-writable directories such as /tmp. For more information, see the documentation of /proc/sys/fs/protected_hardlinks in the proc(5) man page. |
2012-10-15 |
348 |
This note relates to the shell session shown at the top of the page. Depending on factors including the file system type, the size of file created, and system scheduling decisions, you may not always see the behavior shown in this example. Specifically, by the time that the second df command is executed (via system()) the blocks of the closed file may not yet have been freed, so that the output of the second df shows no change in the amount of disk space used in the file system. As a workaround, adding a sufficiently long sleep() call immediately after the close() call in dirs_links/t_unlink.c should ensure that the file blocks have been freed; in all cases that I tested (including very large file sizes), sleep(1) was sufficient to ensure that the file space was freed by the time of the second df command. Note that calling sync() after the close() call does not suffice to eliminate this behavior. Presumably, this is because sync() flushes dirty blocks in the buffer cache, whereas the file blocks in question here are being (asynchronously) deallocated by the kernel. Reported by Yang Yang. |
2011-12-04 |
357 |
Since glibc 2.24, the readdir_r() function has been marked as deprecated, for the reasons discussed in Austin Group bug report 696, this glibc bug report, and in the readdir_r() manual page.
This erratum was updated on 15 Aug 2017 to amend the glibc version where readdir)r() was deprecated from 2.23 to 2.24. |
2016-02-29 |
362 |
Because of a regression that took place in glibc 2.4, the example shell session demonstrating the use of the nftw_dir_tree.c program may (if you are using a glibc version that does not have a fix for the regression) produce different results than are shown on this page. In particular, in more or less the middle of the page there is the following line of output: 1 SLN 2327987 dsl Compare this line with an identical line shown further down the page where the nftw_dir_tree.c program is employed with the –p option, which specifies the use of the FTW_PHYS flag, meaning display information about symbolic links themselves, rather than the files they refer to. The fact that the same i-node number is shown for the dangling symbolic link, dsl, both with and without the use of the FTW_PHYS flag indicates that even when the FTW_PHYS flag is not specified, if nftw() encounters a dangling symbolic link, then it uses lstat() to obtain a stat structure describing the symbolic link and that structure is passed to the callback function. In glibc 2.4, there was a change in behavior that appears to have been unintended. Following that change, in the case where the FTW_PHYS flag is not specified, then when a dangling symbolic link is encountered, the contents of the stat structure that is passed to the callback function are left undefined. (In practice, this typically means that the last stat structure that was previously fetched for a file will be supplied to the callback function.) This changed behaviour of the glibc nftw() implementation differed from every other implementation that I've tested or examined (Solaris, OpenBSD, FreeBSD, musl) and also my reading of POSIX.1, which notes that in the case where FTW_NS is passed in the typeflag argument of the callback function, the contents of the stat structure are undefined, but makes no similar statement regarding the case where FTW_SLN is passed in the typeflag argument (with the implication that the contents of the stat buffer are defined). The older (pre-2.4) glibc implementation of nftw() behaved in the same way as other current implementations. I was already aware that there was an issue regarding the difference between the current glibc nftw() implementation and the behavior of nftw() on other systems, but LaoK's bug report against my book reminded me that I had myself earlier determined that the glibc implementation used to behave the same as other nftw() implementations. This regression led to some bug reports against glibc (Red Hat bugzilla report 1422736 and glibc bug 23501) and Austin bug report 1121 against the POSIX.1 standard. Ultimately, it was resolved that this was a glibc bug, and the regression was fixed in glibc 2.30 (and possibly backported to some earlier glibc versions). This erratum was updated on 2020-07-02 to reflect the fact that the glibc bug has been fixed. Reported by LaoK. |
2017-06-11 |
365 |
Since Section 18.11 was written, some new AT_* flags have been added to various system calls mentioned in this section. Linux 2.6.38 added the AT_NO_AUTOMOUNT flag for fstatat(). This flag can be used to prevent automounting of the terminal component of a pathname given to fstatat(). Linux 2.6.39 added the AT_EMPTY_PATH flag for linkat(), fchownat(), fstatat(), and name_to_handle_at(). (An explanation of the last of these system calls can be found on LWN.net.) This flag allows empty relative pathnames to be specified for these system calls, in which case the calls operate on the directory file descriptor. |
2011-06-26 |
378 |
Linux 2.6.36 adds a new input flag for inotify, IN_EXCL_UNLINK, that prevents children of a watched directory from generating events for a directory after they have been unlinked from that directory. This flag would slot into Table 19-1, just below IN_DONT_FOLLOW. Further information can be found in the inotify(7) manual page. |
2011-05-08 |
379 |
In the discussion of the IN_ATTRIB event in the first bullet point, it is worth noting that the "link count changed" case also includes deletion of a file. However, there isn't sufficient space on the page to add this information. Reported by Bill McConnaughey. |
2011-07-18 |
380 |
At the end of the first of the two bullet points at the bottom of this page, there is the following sentence:
The semantics described in that sentence were by design, The idea being that if an application employed the IN_ONESHOT flag, then it knew that on the next event the watch would be dropped, and did not need the "noise" of an event to be informed of that fact. However, starting with kernel 2.6.36, an IN_ONESHOT event is generated in this case. This change in semantics was almost certainly an unintended consequence of code reworking that went on during the development of the fanotify API. |
2014-03-28 |
386 |
At the end of Chapter 19, rather more that could have been said about the limitations of the inotify API. In the meantime, I have made some substantial revisions to the inotify(7) man page to discuss limitations and pitfalls that one should be aware of when using the API. Having read Chapter 19, it's strongly advisable to read that manual page. |
2014-04-06 |
406 |
Starting with version 2.32 (August 2020), the sys_siglist variable described in Section 20.8 is no longer exported by glibc. |
2020-10-10 |
426 |
Regarding Table 21-1, POSIX.1-2008 Technical Corrigendum 1 (POSIX.1-2013) adds the following functions to the list of async-signal-safe functions: fchdir(), pthread_kill(), pthread_self(), and pthread_sigmask(). POSIX.1-2008 Technical Corrigendum 2 (POSIX.1-2016), adds even more functions to the list of async-signal-safe functions, including longjmp() and siglongjmp(), as well as a host of functions that deal with strings, wide-character strings, and memory comparisons and copying. For details, see the new signal-safety(7) manual page. Explanation:
|
2015-09-11 |
429 |
A small-font note near the bottom of this page says
Since the deprecation of _BSD_SOURCE in glibc 2.19, _BSD_SOURCE no longer has this effect for setjmp(). For further details, see the setjmp(3) manual page. |
2017-08-15 |
442 |
In Section 21.5, in the first paragraph following the numbered list, the error EINTR is described in parentheses as "Interrupted function". This text is the SUSv3 description of this error. However, glibc associates this error with a slightly different text: "Interrupted system call". Reported by Junjiro Okajima. |
2012-01-16 |
444 |
A bullet point at the bottom of this page notes that a read from an inotify file descriptor is never restarted, regardless of the setting of the SA_RESTART flag. However, starting with Linux 3.8, the SA_RESTART flag does cause a read from an inotify file descriptor to be restarted when interrupted by a signal handler. |
2014-12-11 |
445 |
Under the heading Unhandled stop signals can generate EINTR for some Linux system calls, it is noted that certain system calls can produce the EINTR error even when there is no signal handler. Among the operations listed here are reads from inotify file descriptors. However, starting with Linux 3.8, reads from inotify file descriptors no longer demonstrate this behavior. |
2014-12-11 |
450 |
With respect to Table 22-1, Linux 3.0 added a new specifier, %E. This specifier is replaced by the pathname of the executable file, with slashes (/) substituted by exclamation marks (!). (The substitution is required because slashes can't form part of a filename—they delimit the filename components of a pathname.) Reported by Junjiro Okajima. |
2012-01-16 |
450 |
With respect to Table 22-1, Linux 3.7 added a new specifier, %P. This specifier is replaced by the PID of the process as seen in the initial PID namespace (whereas the existing %p specifier is replaced by the PID in the PID namespace where the process resides). |
2014-03-14 |
450 |
With respect to Table 22-1, Linux 3.12 added a new specifier, %d. This specifier is replaced by the "dumpable" mode of the process (the same value as is returned by the prctl(2) PR_GET_DUMPABLE operation). |
2014-03-14 |
458 |
Although I refer to sigqueue() twice on this page (and once on page 477) as a system call, strictly speaking, it is a library function (layered on top of the Linux rt_sigqueueinfo(2) system call). In September 2011, I made changes to the Linux man pages to more accurately reflect that fact, documenting the underlying system call and moving the sigqueue() manual page from Section 2 (System Calls) to Section 3 (Library Functions). |
2011-09-30 |
468 |
Ideally, the following information regarding portability should have been included at the bottom of this page:
However, there isn't sufficient space on the page to include this information. Explanation:
|
2012-02-14 |
491 |
The second paragraph of Section 23.5 says:
Starting with glibc 2.17, this is no longer true. This change was requested in glibc bug 14743, so that single-threaded programs using the clock_* functions do not end up incurring the cost of dragging in libpthread. The change affects clock_getcpuclockid(), clock_getres(), clock_gettime(), clock_nanosleep(), and clock_settime(). |
2012-10-29 |
491 |
Since Section 23.5 was written, some new clocks have been added to the POSIX clocks API. Linux 2.6.39 adds CLOCK_BOOTTIME. This clock is the same as CLOCK_MONOTONIC, except that it includes time that the system has spent in suspended state. The new clock is intended for applications that want a monotonically increasing clock and also want to be aware of time the system has been suspended. Linux 3.0 adds two clocks to the POSIX clocks API: CLOCK_BOOTTIME_ALARM and CLOCK_REALTIME_ALARM. These clocks behave identically to CLOCK_REALTIME and CLOCK_BOOTTIME, but the _ALARM suffixed clocks will wake the system if it is suspended. A new CAP_WAKE_ALARM capability governs the use of these clocks. |
2011-06-26 |
492 |
Relevant to Section 23.5.2: since Linux 2.6.39, the new clock_adjtime() system call provides an interface to adjust the value of a POSIX clock (if that clock supports the interface) in the same manner as the adjtimex(2) system call. |
2011-06-26 |
508 |
Since Linux 3.0, the timerfd_settime() system call supports a further flag, TFD_TIMER_CANCEL_ON_SET. If this flag is set for a CLOCK_REALTIME absolute (TFD_TIMER_ABSTIME) timer, then the timer is expired if the clock is reset. |
2011-06-26 |
519 |
The first paragraph below the listing on this page starts with the following text:
Implicit in that text is the notion that file I/O operations (e.g., read() and write()) are atomic with respect to updates to the file offset. POSIX.1-2008/SUSv4 Section XSI 2.9.7 ("Thread Interactions with Regular File Operations") is explicit on this point:
Among the effects specified by POSIX for various I/O functions is of course updating the current file offset. However, a longstanding bug meant that Linux did not conform to the POSIX requirements (and was not consistent with other implementations such as FreeBSD and Solaris). In short, when performing file I/O system calls, the I/O operation plus accompanying file offset change were not performed atomically on Linux. Consequently, if two process (or threads) shared an open file description (and thus the current file offset, as described in Section 5.4 of TLPI), and performed simultaneous reads or writes, then there was a chance that the blocks of data transferred by those I/O system calls would (incorrectly) overlap with one another. This problem was fixed in Linux 3.14. I made the problem report that led to the fix after Yongzhi Pan reported puzzling results when running my disc_SIGHUP.c program (Listing 34-4) as described on pages 713 and 714 of TLPI. Yongzhi noted that some of the expected output was not appearing and when I dug deeper, I discovered the nonatomicity issue. The reason that I had not discovered the (kernel) problem when I originally wrote the program was that the problem behavior appears much less frequently on single-CPU systems, and I happened to have tested the program on a single-CPU system as I wrote that chapter of the book. After Yongzhi's report, I was immediately (and easily) able to reproduce the behavior he reported on a multi-CPU system. Reported by Yongzhi Pan. |
2014-05-04 |
552 |
The first paragraph on this page includes the following text:
This requirement was indeed added in the 2013 Technical Corrigendum 1 to SUSv4. Reported by Ильдар Низамов (Ildar Nizamov) |
2017-09-14 |
553 |
Section 26.2 discusses the traditional semantics for adoption of orphaned children by the init process. Linux 3.4 added the PR_SET_CHILD_SUBREAPER prctl() operation, which allows a "service manager" process to mark itself as a sort of 'sub-init', so that it adopts all orphaned processes created by the services it starts. All SIGCHLD signals will be delivered to the service manager. There is a corresponding PR_GET_CHILD_SUBREAPER prctl() operation. More recent init frameworks employ the PR_SET_CHILD_SUBREAPER feature to create a dedicated subreaper process that becomes the parent of all orphaned children. On such frameworks, which include systemd (dependent on start-up options) and (the now obsolete) upstart, getppid() will report the new parent PID as the PID of the subreaper process (i.e., a value other than 1) when a process becomes orphaned. Explanation:
|
2012-04-24 |
562 |
Exercise 26-1 asks the reader to verify that after a process becomes orphaned, its parent PID (PPID, as returned by getppid()) becomes 1. Historically, this was true. But on some modern init frameworks such as systemd, a dedicated process (with PID other than 1) takes on the role of adopting orphaned children. Thus, in code that solves the exercise, the PPID of the process will change as the child becomes orphaned, but the change with be to a value other than 1. For further details, see the erratum for page 553. A similar qualification also applies for exercise 26-2. Explanation:
Reported by Matthew Meffan. |
2017-11-02 |
571 |
The last paragraph on the page should have noted that:
Explanation:
|
2010-12-31 |
608 |
At the foot of this page, there is a brief discussion of various CLONE_NEW* that are used with containers. For more information on these flags, see this article series on namespaces that I wrote for LWN.net. |
2013-03-07 |
615 |
In the entry for prctl(PR_SET_PDEATHSIG), the exec() column should say "See notes". In the fourth column, the text should say something like the following:
However, there isn't sufficient space on the page to add this information. |
2012-10-27 |
628 |
In Section 29.7, I could have noted that calling pthread_detach() more than once on the same thread results in unspecified behavior. Explanation:
Reported by Jens Thoms Toerring. |
2011-02-28 |
635 |
Section 30.1.1 discusses statically initialized mutexes, stating that PTHREAD_MUTEX_INITIALIZER can be used only for statically allocated mutexes. This follows the specification in POSIX.1-2008. However, the subsequent Austin Group Defect Report 70 noted that this restriction imposed by the standard arose from the constraints of C89, which was the standard that was current when that detail of the specification was originally written. The defect report notes that because C99 allows structure copying, PTHREAD_MUTEX_INITIALIZER can be used generally to initialize a mutex, regardless of whether it is statically allocated or not. This detail was subsequently clarified in POSIX.1-2013, which removed the restriction that PTHREAD_MUTEX_INITIALIZER can be used only with statically allocated mutexes. The use of pthread_mutex_init() is required only to initialize a mutex with nondefault attributes. This change means that the various statements in TLPI about statically allocated mutexes either no longer hold true or need slight amendment. The affected pages are at least: 635, 639, 640, and 641. |
2017-10-14 |
638 |
A word of caution about the timing statistics for mutexes, file locks, and semaphores that are presented in Section 30.1.3. These statistics were obtained on an x86-32 system. The (relative) performance of the various synchronization methods depends on the hardware architecture and the implementation of each method on that architecture. In cases where you suspect that performance of a synchronization method may be critical to the performance of your application, there is no substitute for application-specific benchmarking on the target architecture. Reported by Stefan Puiu. |
2013-07-18 |
643 |
Section 30.1.1 discusses statically initialized condition variables, stating that PTHREAD_COND_INITIALIZER can be used only for statically allocated condition variables. This follows the specification in POSIX.1-2008. However, the subsequent Austin Group Defect Report 70 noted that this restriction imposed by the standard arose from the constraints of C89, which was the standard that was current when that detail of the specification was originally written. The defect report notes that because C99 allows structure copying, PTHREAD_COND_INITIALIZER can be used generally to initialize a condition variable, regardless of whether it is statically allocated or not. This detail was subsequently clarified in POSIX.1-2013, which removed the restriction that PTHREAD_COND_INITIALIZER can be used only with statically allocated condition variables. The use of pthread_cond_init() is required only to initialize a condition variable with nondefault attributes. This change means that the various statements in TLPI about statically allocated mutexes either no longer hold true or need slight amendment. The affected pages are at least: 643, 651, and 652. |
2017-10-14 |
664 |
In version 2.32, glibc removed the symbols _sys_nerr and _sys_errlist. As a consequence, the code example shown on this page (Listing 31-1, threads/strerror.c) will no longer compile on systems that have glibc 2.32 or later. |
2020-10-07 |
666 |
In version 2.32, glibc removed the symbols _sys_nerr and _sys_errlist. As a consequence, the code example shown on this page and the following page (Listing 31-3, threads/strerror_tsd.c) will no longer compile on systems that have glibc 2.32 or later. |
2020-10-07 |
669 |
In version 2.32, glibc removed the symbols _sys_nerr and _sys_errlist. As a consequence, the code example shown on this page (Listing 31-4, threads/strerror_tls.c) will no longer compile on systems that have glibc 2.32 or later. |
2020-10-07 |
679 |
In Listing 32-2 thread/thread_cleanup.c, calls to pthread_mutex_lock() and pthread_mutex_unlock() should surround the assignment to the global variable glob, so that the code reads: printf("main: about to signal condition variable\n"); s = pthread_mutex_lock(&mtx); if (s != 0) errExitEN(s, "pthread_mutex_lock"); glob = 1; s = pthread_mutex_unlock(&mtx); if (s != 0) errExitEN(s, "pthread_mutex_unlock"); s = pthread_cond_signal(&cond); if (s != 0) errExitEN(s, "pthread_cond_signal"); The above change has been made in the source code distribution. However, there isn't sufficient space on the page to make this change in the printed book. Reported by Jingtian Zhang. |
2014-03-09 |
704 |
The paragraph immediately preceding Section 34.3 says: Since the deprecation of _BSD_SOURCE in glibc 2.19, _BSD_SOURCE no longer has this effect for setpgrp() and getpgrp(), For further details, see the setpgrp(2) manual page. |
2017-08-15 |
708 |
A small-font note at the bottom of the page states: If there is no foreground process group for this terminal, tcgetpgrp() returns a value greater than 1 that doesn't match the ID of any existing process group. The text could have said a little more about what kind of scenarios may result in such a return value. The most likely scenario is that (all of the processes in) the foreground process terminated, and no other process group was subsequently made the foreground process group for the terminal. In this case, tcgetpgrp() will return the process group ID of the terminated process group. In practice, such situations are rare: normally the foreground process group consists of (child) processes created by the shell, and when the shell observes that those processes have terminated, it makes itself the foreground process group for the terminal. However, if, for example, an application program creates a child process in a new process group, makes that process group the foreground process group, and then the child process terminates, then the shell will not notice that the foreground process group has disappeared and will thus not make itself the foreground group. Reported by Jimm Chen. |
2024-02-09 |
710 |
Section 34.6.1 notes that when a shell is sent a SIGHUP signal (because it is the controlling process and there was a terminal hangup), it in turns sends a SIGHUP signal to each of the process groups (jobs) that it has created. It should be noted that the latter behavior is dependent on a shell option, and on many modern systems the option is disabled by default. (In bash the option is set using the command shopt -s huponexit.) |
2017-10-16 |
714 |
A longstanding kernel bug means that if you are running the disc_SIGHUP.c program on a multi-CPU system with a Linux kernel version of 3.13 or earlier, then it is likely that you won't see the results shown at the top of this page. For further details, see the erratum note for page 519. Reported by Yongzhi Pan. |
2014-05-04 |
734 |
The addition of the autogroup feature in Linux 2.6.38 caused significant changes to the semantics of the nice value. For details, see the sched(7) manual page. |
2016-12-02 |
744 |
See the third bullet point at the top of the page. Starting with Linux 2.6.39, the limitation on modifying the SCHED_IDLE scheduling policy changes. An unprivileged SCHED_IDLE thread can now switch to another policy as long as its current nice value falls within the range permitted by the RLIMIT_NICE resource limit (see page 736). |
2011-06-26 |
747 |
A small-font note at the foot of the page notes that the realtime round-robin timeslice is 0.1 seconds (100 milliseconds). Linux 3.9 adds the /proc/sys/kernel/sched_rr_timeslice_ms file, which can be used to view and modify the timeslice value. The value in this file is expressed in milliseconds, and the default is 100. Writing "0" to the file restores the value to the default. |
2013-03-22 |
755 |
Linux 2.6.36 adds a new system call, prlimit(), that allows the caller to both set and retrieve its own resource limits (including retrieving the old limit at the same time as a new limit is set) and (with suitable permissions) perform the same task for other processes. See the manual page. |
2011-05-08 |
755 |
The small-font note at the bottom of the page notes that /proc/PID/limits is readable only by the file owner. Linux 2.6.36 (the very next release after publication of TLPI) changed the permissions of this file so that it is readable by all users. |
2012-11-24 |
760 |
Starting with version 2.13, glibc has implemented wrapper functions for getrlimit() and setrlimit() that use the prlimit() system call mentioned in the notes for page 755 to work around the problem described in the paragraph at the top of this page. |
2011-05-08 |
761 |
Regarding the description of RLIMIT_CPU (and RLIMIT_RTTIME on page 764), it's worth mentioning that, after a report from Trevor Woerner, I added the following text to the getrlimit(2) manual page, under the heading BUGS:
This behavior is something of a Linux oddity. No other implementation that I know of does this (I tested Solaris 10, FreeBSD 9.0 and OpenBSD 5.1), and, as I noted in the manual page, I suspect it isn't standards conformant. The current description in TLPI about delivery of SIGXCPU when the RLIMIT_CPU and RLIMIT_RTTIME soft limits are exceeded is correct, but the underlying implementation detail that I added to the manual page may of interest to readers who, like Trevor, try digging deeply into the details of the behavior when these limits are hit by an application. Reported by Trevor Woerner. |
2012-11-23 |
764 |
The treatment of the RLIMIT_RTTIME soft limit when a SIGXCPU signal is delivered is the same as for the RLIMIT_CPU soft limit, as described in the erratum for page 761. Reported by Trevor Woerner. |
2012-11-23 |
768 |
A small-font note near the top of this page mentions pdflush as an example of a kernel thread. The example is accurate, but obsolete, since the pdflush mechanism was replaced in Linux 2.6.32. See the erratum for page 241. Reported by Junjiro Okajima. |
2012-08-21 |
792 |
The C11 standard (ratified by ISO on 8 Dec 2011), officially removes the dangerous function gets() from the language specification. From version 2.16, glibc does not expose the definition of gets() if the _ISOC11_SOURCE feature test macro is defined. |
2012-01-18 |
793 |
The small-font note somewhat more than half-way down the page states that glibc does not implement strlcpy(). However, starting in version 2.38 (released in 2023), glibc does implement this function. |
2023-08-05 |
801 |
Linux 2.6.38 adds a new capability, CAP_SYSLOG, used (instead of CAP_SYS_ADMIN) to govern privileged syslog(2) operations. |
2011-05-08 |
801 |
Linux 3.0 adds a new CAP_WAKE_ALARM capability, which governs the use of the CLOCK_BOOTTIME_ALARM and CLOCK_REALTIME_ALARM clocks. (See also the note for page 491.) |
2011-06-26 |
801 |
Linux 3.5 adds a new CAP_EPOLLWAKEUP capability, which governs the use of the epoll EPOLLWAKEUP flag. (See also the note for page 1359.) |
2012-07-16 |
823 |
The example program (loginacct/dump_utmpx.c) discussed at the foot of this page provides functionality similar to the utmpdump(1) command. |
2013-02-12 |
853 |
Regarding the discussion under the heading The ELF DT_RPATH and DT_RUNPATH entries, it's worth noting that some distributions enable --enable-new-dtags by default, among them openSUSE and Gentoo, In upstream binutils, and in many other distributions, this flag is disabled by default. Reported by Trevor Woerner. |
2012-12-30 |
853 |
The example in the middle of this page shows that when the --enable-new-dtags linker option is specified, then both a DT_RPATH entry and a DT_RUNPATH entry are created in the executable. The linker did this as an interim measure for the benefit of old dynamic linkers that understood DT_RPATH but not DT_RUNPATH. DT_RUNPATH support was added to the glibc dynamic linker in 1999. 14 years later, in 2013 (binutils-2.24), the static linker was changed so that when the --enable-new-dtags linker option is specified, only a DT_RUNPATH entry is produced in the executable. The presumption is that all modern systems by now have a dynamic linker that understands DT_RUNPATH. Consequently, if repeating the example shown on this page, the output of the objdump command will be just: $ objdump -p prog | grep PATH RUNPATH /home/mtk/pdir/d1 |
2017-04-14 |
864 |
Pages 863 and 864 discuss the rather clumsy cast that is required when assigning the value returned by dlsym() to a function pointer: *(void **) (&funcp) = dlsym(handle, symbol); Here, SUSv3 and SUSv4 were accepting the requirements of ISO C standard, which leaves the results of casting between function pointers and void * undefined. The 2013 Technical Corrigendum (TC1) to the standard improves matters, by requiring conforming implementations to allow void * to be assigned to a function pointer. As a result, such assignments can be done using more natural casts of the form: funcp = (int (*) (int)) dlsym(handle, symbol); Note, however, that current compilers may still complain about this cast (e.g., gcc -pedantic may give warnings). |
2014-01-02 |
872 |
The last part of Section 42.3 discusses the use of objdump –t to display information from the symbol table of an executable, in order to see version tag dependencies. Yang Yang notes that using objdump –T (which yields the same information for the cases discussed in the text, but in a slightly different form) may be preferable. The reason is that objdump –T obtains its information from the ELF dynamic symbol table (.dynsym), which is always present in a dynamically linked binary. By contrast, objdump –t obtains its information from the standard symbol table (.symtab), which is not present if the executable has been stripped. The blog post Inside ELF Symbol Tables by Ali Bahrami provides a nice introduction to the two types of symbol tables. Reported by Yang Yang. |
2012-01-27 |
874 |
Immediately preceding Section 42.6, there is the following sentence:
This should read something like:
The above change addresses two problems with the existing text. First of all, Section 42.5 does not clearly explain how the names in LD_PRELOAD are interpreted. Second, some of the subtleties of the handling set-user-ID and set-group-ID programs were omitted in the existing text. Although it would be nice to make this change to the text, unfortunately, there isn't sufficient space on the page to make the change. Reported by Junjiro Okajima. |
2012-08-24 |
926 |
Toward the bottom of the page, there is the following text: The glibc ftok() algorithm is similar to that employed on other UNIX implementations, and suffers a similar limitation: there is a (very small) possibility that two different files could yield the same key value. This can occur because there is a chance that the least significant bits of an i-node number could be the same for two files on different file systems, coupled with the possibility that two different disk devices (on a system with multiple disk controllers) could have the same minor device number. Yaakov Eisenberg points out that there is another (somewhat more likely) possibility: the least significant bits of the inode numbers of two files on the same file system are the same in their least significant bits. (However, coupled with the fact their are 256 different possible proj values, the chances of a collision when using ftok() remain small.) Reported by Yaakov Eisenberg. |
2024-01-09 |
1011 |
Regarding the discussion of IPC_RMID, Linux 3.1 added a new /proc/sys/kernel/shm_rmid_forced file that can be used to control the handling of System V shared memory segments that have no attached process. The default value in this file is 0, which provides the traditional behavior: unattached segments remain in existence and can be reattached at a later point in time by another process. If the value in shm_rmid_forced is 1, then the effect is as though an IPC_RMID operation is performed on all shared memory segments that currently exist and that are created in the future. This means that those segments will be destroyed as soon as the last process detaches from them. This can be useful to ensure that shared memory segments are counted against the resource usage and limits of at least one process, but it is nonstandard and has the potential to break applications that depend on the traditional behavior. |
2013-03-22 |
1023 |
The program in Listing 49-1 (mmap/mmcat.c) does not correctly handle a zero-length input file. Given such a file, zero will be passed as the second argument of mmap(), which will fail with the error EINVAL. The fix for this problem is to add the following two lines of code before the call to mmap(): if (sb.st_size == 0) exit(EXIT_SUCCESS); However, there isn't sufficient space on the page to make this change. (The change has, however, been made in the "distribution" version of the code for the book.) Reported by Liu Jiaming. |
2013-10-22 |
1032 |
The small-font note in the first half of the page that begins "If we take no further action" contains a reference to the obsolete pdflush kernel thread. As noted in an erratum for page 241, pdflush was replaced by a different mechanism in kernel 2.6.32. |
2012-08-21 |
1040 |
In Linux 2.6.36, the OOM killer underwent another rewrite. Following the rewrite, the /proc/PID/oom_adj file can still be used to influence the OOM killer, but this file is now deprecated in favor of the new /proc/PID/oom_score_adj file. In addition, the logic to select a candidate for OOM killing was simplified to take into account just the amount of memory used by the process and whether or not it is privileged. For further information, see the proc(5) man page. Explanation:
|
2012-12-21 |
1041 |
Because it has few users, and adds significant complexity to the kernel code, the remap_file_pages() system call has been deprecated. Eventually, it will be replaced by a slower in-kernel emulation (that maintains the ABI). For further information, see the LWN.net article, The possible demise of remap_file_pages(). |
2014-06-12 |
1055 |
To the first small-font note, about two thirds of the way down the page, it can be noted that Linux 2.6.38 added two new flags to the madvise() system call: MADV_HUGEPAGE and MADV_NOHUGEPAGE. These flags enable and disable an attribute on the memory region that indicates that it is important that the region be backed by huge pages. (Huge pages are briefly described on page 999.) |
2011-06-26 |
1055 |
To the first small-font note, about two thirds of the way down the page, it can be noted that Linux 3.4 added two new flags to the madvise() system call: MADV_DONTDUMP and MADV_DODUMP. The MADV_DONTDUMP flag specifies that an address range should not be included in core dumps. The MADV_DODUMP flag reverses the effect of MADV_DONTDUMP. |
2012-04-24 |
1061 |
With respect to the discussion of portability of POSIX IPC in the last bullet point on this page, it's worth noting the following:
|
2013-10-09 |
1080 |
The program in Listing 52-6 (pmsg/mq_notify_sig.c) does not handle the case where a message has already been placed on the queue by the time the first attempt is made to register for message notification. For an example of how that case could be handled, see mq_notify_via_signal.c. |
2014-12-01 |
1082 |
The program in Listing 52-7 (pmsg/mq_notify_thread.c) does not handle the case where a message has already been placed on the queue by the time the first attempt is made to register for message notification. For an example of how that case could be handled, see mq_notify_via_thread.c. |
2014-12-01 |
1086 |
In Linux 3.5, various details of the default values, limitations on modification, and interpretation with respect to privileged processes changed for the message queue limit files msg_max, msgsize_max, and queues_max. Full details can be found in the mq_overview(7) manual page. In addition, Linux 3.5 added two new /proc files can be used to read and modify the values that are used to provide defaults when a POSIX message queue is created using an mq_open() call in which the attr argument is specified as NULL. The /proc/sys/fs/mqueue/msg_default file defines the default value used for a new queue's mq_maxmsg attribute. The default value in this file is 10. The /proc/sys/fs/mqueue/msgsize_default file defines the default value used for a new queue's mq_msgsize attribute. The default value in this file is 8192. |
2013-03-22 |
1129 |
With respect to the discussion of deadlock detection in Section 55.3.1, it's worth noting that there are limits to the kernel's deadlock-detection algorithm. Most notably, circular deadlocks involving a long (> 10) chain of locks are not detected (meaning that the processes concerned will remain blocked indefinitely waiting on each other's locks). For further details, see the fcntl(2) manual page. |
2014-05-20 |
1137 |
Starting with version 3.15, Linux adds a new (as yet unstandardized) lock type: an open file description (OFD) lock. OFD locks operate in a similar manner to traditional process-associated record locks (created using fcntl(2) F_SETLK), but have inheritance and release semantics that are the same as flock(2). OFD locks therefore do not suffer the defects of traditional process associated locks: they are not automatically released when a process closes any file descriptor referring to the file, and they can be used within a multithreaded application to synchronize file access between threads. For details, see the fcntl(2) man page. |
2014-05-01 |
1140 |
The problems with mandatory locking have long been recognized by kernel developers, and there is a widespread belief that because of these problems this feature has few or perhaps no users. Therefore, since Linux 4.5, mandatory locking has been made an optional feature (governed by a kernel option), as a stepping stone toward eventually removing the feature completely. More information can be found in Jon Corbet's LWN.net article Optional mandatory locking. (This note was updated on 2016-04-18.) |
2015-12-10 |
1152 |
Two points regarding the small-font note at the bottom of the page:
|
2015-12-20 |
1161 |
In the small-font note about three quarters of the way down the page that discusses MSG_TRUNC in relation to recvmsg(), it is worth noting that MSG_TRUNC can be specified in the flags argument of recv() and recvfrom(). In this case, if a datagram is larger than length, the call returns the actual size of the datagram. The caller can detect the fact that truncation has occurred because the return value exceeds length. This feature is a nonstandardLinux extension. |
2013-11-04 |
1171 |
The first paragraph on this page notes that UNIX domain datagram sockets are reliable—datagrams are delivered in order and unduplicated. This is true on all of the implementations that I know of, but there is one detail that varies across implementations. On Linux, if the receiving UNIX domain datagram socket is full, then a process that sends a datagram to that socket will block. On some other implementations (e.g., FreeBSD), the sender will get an error (ENOBUFS) in this case. A portable application would handle this error by waiting and then retrying the send operation. |
2013-02-05 |
1272 |
Linux 3.6 and 3.7 added code to implement TCP Fast Open, a feature that, in certain circumstances, allows a round-trip time to be saved during TCP connection set up. (In essence, TCP Fast Open allows a client that has previously authenticated itself to send data in the initial SYN segment of the three-way handshake.) For details, see my LWN.net article, TCP Fast Open: expediting web services. |
2012-10-15 |
1284 |
The small-font note about one third of the way down the page states that a sendmmsg() system call is likely to be implemented in the future. This system call was added in Linux 3.0. |
2011-06-26 |
1322 |
On the last line of this page, Michael Sweet's Serial Programming Guide for POSIX Operating Systems is noted as being online at http://www.easysw.com/~mike/serial/. This is no longer the case. The guide is now available as a book and ebook from lulu.com. The original HTML document can still be found online in various locations, but the license of those copies is unclear. Reported by MingYi Liao. |
2013-08-12 |
1350 |
Linux 3.6 added a new fcntl() flag, F_GETOWNER_UIDS, which can be used to retrieve the real and effective user IDs associated with a previous F_SETOWN call. (Those UIDs determine the rules for sending a signal to another process for signal-driven I/O.) The third argument of the call is of type uid_t *, and should point to a two-element array that stores the real user ID and effective user ID. This feature is intended for use by the checkpoint/restore facility and is only provided if the kernel was configured with the CONFIG_CHECKPOINT_RESTORE option. |
2012-10-15 |
1355 |
One of the things I aimed to do in TLPI was come up with as many good diagrams as possible. See this LWN article for a diagram that I wish I'd thought of when I was writing the introductory piece of Section 63.4. |
2012-10-18 |
1357 |
In Linux 3.7, the epoll_ctl() adds a new flag, EPOLL_CTL_DISABLE that allows multithreaded applications to safely disable monitoring of a file descriptor. |
2012-10-15 |
1359 |
Linux 3.5 adds a new epoll flag, EPOLLWAKEUP. The new flag can be supplied in a call to epoll_ctl() to prevent system suspend while epoll events are available for the specified file descriptor. Use of this flag requires that the caller have the EPOLLWAKEUP capability, which was also added in Linux 3.5. |
2012-07-16 |
1388 |
In the discussion on closing file descriptors referring to the pseudoterminal master near the end of this page, there is the following text: A read() from the slave device returns end-of-file (0). This statement was correct at the time of writing. However, since publication there appears to have been a subtle change in behavior, which could be summarized with the following text: A read() from the slave device that is blocked at the time that the master device is closed fails with the error EIO. A read() from the slave device that is performed after the master device is closed returns end-of-file (0). As far as I can tell, this change was a (probably unintended) consequence of kernel commit 699390354da (pty: Ignore slave pty close() if never successfully opened) that was merged in Linux 3.9. |
2017-04-02 |
1406 |
The bullet point at the bottom on the page states: If we are processing multiple command-line vectors or rescanning the same command line, then we must explicitly reset optind to 1. This is the POSIX-specified way of doing things. However, a GNU extension also allows the possibility of setting optind to 0 to ensure that certain GNU-specific initializations are performed. Further details can be found in the getopt(3) manual page. Reported by 맹규호. |
2019-01-05 |
1438 |
The web site for Dave Butenhof's book, Programming with POSIX Threads, has gone away, and its new location is not yet confirmed. In the meantime, you can find the code for the book at http://www.informit.com/store/programming-with-posix-threads-9780201633924. |
2013-11-09 |
The following fixes and improvements were applied in the fifteenth and later printings of the book.
Page | Fix | Reported |
53 |
Two related changes are made on this page. About two thirds of the way down the page, change: However, this approach is inefficient because errno is defined in threaded programs as a macro that expands into a function call that returns a modifiable lvalue. to: However, this approach is inefficient because errno is defined in threaded programs as a macro that produces a modifiable lvalue via a function call that returns a pointer to a thread-specific storage area. In the small-font note at the bottom of the page, change: Under the POSIX threads API, errno is redefined to be a function that returns a pointer to a thread-specific storage area (see Section 31.3). to: Under the POSIX threads API, errno is defined as a macro that produces a modifiable lvalue by dereferencing the result of calling a function that returns a pointer to a thread-specific storage area (see Section 31.3). Explanation:
Reported by Yaakov Eisenberg. |
2022-12-04 |
54 |
Several small changes are required to fix some formatting issues that were introduced in the thirteenth print run. In the first paragraph, change "out-put" to "output". In the second paragraph, change "pro-gram" to "program". In the first line of Listing 3-3, the string "error_functions.c" is misplaced. It should appear at the end of the end of the previous line (so that the end of that line reads "lib/error_functions.c"). In Listing 3-3, the following lines:
should read:
Reported by Yaakov Eisenberg. |
2022-12-04 |
129 |
In the last line on this page, change: Returns 0 on success, or a nonzero on error to: Returns 0 on success, or nonzero on error Reported by Yaakov Eisenberg. |
2023-02-09 |
143 |
In the shell session shown at the bottom of the page, change: $ ./free_and_sbrk 1000 10240 1 500 1000 Initial program break: 0x804a6bc Allocating 1000*10240 bytes Program break is now: 0x8a13000 Freeing blocks from 500 to 1000 in steps of 1 After free(), program break is: 0x852b000 to: $ ./free_and_sbrk 1000 10240 1 501 1000 Initial program break: 0x804a6bc Allocating 1000*10240 bytes Program break is now: 0x8a13000 Freeing blocks from 501 to 1000 in steps of 1 After free(), program break is: 0x852b000 Explanation:
Reported by Joaquín Moreno. |
2024-01-09 |
150 |
In the bullet point at the top of the page, change: The address of the allocated memory is returned in memptr. to: The address of the allocated memory is returned in *memptr. Reported by Yaakov Eisenberg. |
2023-02-09 |
155 |
In the last paragraph of Section 8.2, change: Not all UNIX implementations provide this feature, and on implementations where it is provided the details of locations and APIs vary. to: Not all UNIX implementations provide this feature, and on implementations where it is provided the details of the file locations and APIs vary. Explanation:
Reported by Yaakov Eisenberg. |
2023-02-09 |
168 |
In the last sentence of the first paragraph of Section 9.3, a small formatting fix to change: (The terms set-user-ID program and set-group-ID program are sometimes abbreviated as set-UID program and set-GID program.) to: (The terms set-user-ID program and set-group-ID program are sometimes abbreviated as set-UID program and set-GID program.) Reported by Yaakov Eisenberg. |
2023-02-09 |
187 |
In the small-font note at the top of the page, change: The tz_minuteswest field indicates the number of minutes that must be added to times in this zone to match UTC, with a negative value indicating that an adjustment of minutes to the east of UTC to: The tz_minuteswest field indicates the number of minutes that must be added to times in this zone to match UTC, with a negative value indicating an adjustment of minutes to the east of UTC Reported by Yaakov Eisenberg. |
2023-02-09 |
234 |
In the first sentence after the heading in the middle of the page, change: The kernel performs the same number of disk accesses, regardless of whether we perform 1000 writes of a single byte or a single write of a 1000 bytes. to: The kernel performs the same number of disk accesses, regardless of whether we perform 1000 writes of a single byte or a single write of 1000 bytes. Reported by Yaakov Eisenberg. |
2023-02-25 |
248 |
In Listing 13-1 (filebuff/direct_read.c), change one line in the comment in the code:
to:
Explanation:
Reported by Yaakov Eisenberg. |
2023-02-25 |
253 |
Change the last two sentences of the second-to-last paragraph: Tracks themselves are divided into a number of sectors, each of which consists of a series of physical blocks. Physical blocks are typically 512 bytes (or some multiple thereof) in size, and represent the smallest unit of information that the drive can read or write. to: Tracks themselves are divided into a number of sectors, which are typically 512 bytes (or some multiple thereof) in size, and represent the smallest unit of information that the drive can read or write. Reported by Yaakov Eisenberg. |
2023-02-25 |
257 |
In the second-to-last paragraph, change: For even larger files, the fourteenth pointer (numbered 13 in the diagram) is a double indirect pointer—it points to blocks of pointers that in turn point to blocks of pointers that in turn point to data blocks of the file. to: For even larger files, the fourteenth pointer (numbered 13 in the diagram) is a double indirect pointer—it points to a block pointers that in turn point to blocks of pointers that in turn point to data blocks of the file. Reported by Yaakov Eisenberg. |
2023-02-25 |
258 |
This report applies only for the PDF version of the book, and involves two fixes to Figure 14-2. In print run 3, a fix was made to Figure 14-2, but the fix was was accidentally reverted in print run 6. The same fix must be reapplied. In the "Key" box in the upper right hand corner of Figure 14-2, change:
to:
In addition, a formatting glitch appeared in print run 6, such that the bottom edge of a box in the diagram has been lost. This will be fixed in the next PDF version. Reported by Yaakov Eisenberg. |
2023-02-25 |
292 |
In the middle of this page, change: An unprivileged process can use chown() to change the group ID of a file that it owns (i.e., the process’s effective user ID matches the user ID of the file) to any of the groups of which they are a member. to: An unprivileged process can use chown() to change the group ID of a file that it owns (i.e., the process’s effective user ID matches the user ID of the file) to any of the groups of which it is a member. Reported by Yaakov Eisenberg. |
2023-04-30 |
294 |
In the fourth line of code from the top of this page, change:
to:
Reported by Yaakov Eisenberg. |
2023-02-26 |
381 |
In the second bullet point at the top of the page, change: We describe the IN_Q_OVERFLOW in Section 19.5, to: We describe the IN_Q_OVERFLOW event in Section 19.5, Reported by Yaakov Eisenberg. |
2023-04-06 |
424 |
in Listing 21-1 (signals/nonreentrant.c), change:
to: static char *str2; /* Set from argv[2] */ static volatile int handled = 0; /* Counts number of calls to handler */ Explanation:
Reported by Joaquín Moreno. |
2024-03-11 |
444 |
A bit more than one third of the way down this page, delete a sentence: The sem_wait() and sem_timedwait() functions used to decrement a POSIX semaphore. (On some UNIX implementations, sem_wait() is restarted if the SA_RESTART flag is specified.) to: The sem_wait() and sem_timedwait() functions used to decrement a POSIX semaphore. Reported by Yaakov Eisenberg. |
2023-04-30 |
445 |
About half way down this page, change: In kernels before 2.6.24, poll() also exhibited this behavior, as did sem_wait(), sem_timedwait(), futex(FUTEX_WAIT), in kernels before 2.6.22, msgrcv() and msgsnd() in kernels before 2.6.9, and nanosleep() in Linux 2.4 and earlier. to: In kernels before 2.6.24, poll() also exhibited this behavior, as did sem_wait(), sem_timedwait(), and futex(FUTEX_WAIT) in kernels before 2.6.22, msgrcv() and msgsnd() in kernels before 2.6.9, and nanosleep() in Linux 2.4 and earlier. Explanation:
Reported by Yaakov Eisenberg. |
2023-04-30 |
466 |
Near the top of the page, change: Uses sigsuspend() to unblock SIGINT and SIGQUIT ... to: Use sigsuspend() to unblock SIGINT and SIGQUIT ... Reported by Yaakov Eisenberg. |
2023-04-30 |
477 |
In the second paragraph on this page, change: Note that this function is defined with different calling signatures in the System V and BSD APIs. to: Note that although a function with this name exists in both the System V and BSD APIs, the int argument is interpreted differently in the two APIs. Reported by Yaakov Eisenberg. |
2023-05-05 |
491 |
About two thirds of the way down the page, in the paragraph beginning "The time value", change the last sentence in the paragraph: The clock_getres() system call returns via the argument res, a pointer to a timespec structure containing the resolution of the clock specified in clockid. to: The clock_getres() system call returns the resolution of the clock specified in clockid in the timespec structure pointed to by res. Explanation:
Reported by Yaakov Eisenberg. |
2023-05-05 |
499 |
In the second paragraph of Section 23.6.3, change: The curr_value.it_value field returns the time until next timer expiration, even if this timer was established as an absolute timer using TIMER_ABSTIME. to: The curr_value.it_value field returns the time until the next timer expiration, even if this timer was established as an absolute timer using TIMER_ABSTIME. Reported by Yaakov Eisenberg. |
2023-05-06 |
504 |
This is a correction for the PDF version of the book only. In the second sentence of Section 23.6.7, the text "30" should hyperlink to Chapter 30 in the PDF. However, this link is broken and needs repairing to point to the correct location. Reported by Yaakov Eisenberg. |
2023-05-19 |
514 |
In the small-font note at the top of this page, change: generally only one of the parent and child terminate by calling exit(); to: generally only one of the parent and child terminates by calling exit(); Reported by Yaakov Eisenberg. |
2023-05-19 |
514 |
In the the first bullet point at the top of the page, fix a formatting error by changing: Second, the termination status of the child is returned in the status argument of wait(). to: Second, the termination status of the child is returned in the status argument of wait(). Reported by Yaakov Eisenberg. |
2023-05-19 |
535 |
Fix a page reflow error that first appeared in print run 5, so that the code snippet at the bottom of the page does not split badly onto the top of page 536. Reported by Yaakov Eisenberg. |
2023-05-19 |
621 |
In the second paragraph, change: On Linux, a thread-specific errno is achieved in a similar manner to most other UNIX implementations: errno is defined as a macro that expands into a function call returning a modifiable lvalue that is distinct for each thread. to: On Linux, a thread-specific errno is achieved in a similar manner to most other UNIX implementations: errno is defined as a macro that produces a modifiable lvalue by dereferencing the pointer returned by a function that returns a pointer to a thread-specific data area. Explanation:
|
2022-12-20 |
624 |
In the prototype box for pthread_equal() near the bottom of the page, change: Returns nonzero value to: Returns a nonzero value Reported by Yaakov Eisenberg. |
2023-06-09 |
644 |
In the third paragraph from the bottom of the page, change: By contrast, pthread_cond_broadcast() handles the case where the waiting threads are designed to perform different tasks (in which case they probably have different predicates associated with the condition variable). to: By contrast, pthread_cond_broadcast() handles the case where the waiting threads are designed to perform different tasks. In this case, the threads probably have different predicates associated with the condition variable (see Section 30.2.3). Reported by Yaakov Eisenberg. |
2023-08-03 |
649 |
Near the top of Listing 30-4 (threads/thread_multijoin), change:
to:
Explanation:
Reported by Yaakov Eisenberg. |
2023-08-05 |
653 |
In the fourth function prototype, change: Boolean lookup(char *key, void **value) to:
Reported by Yaakov Eisenberg. |
2023-06-09 |
660 |
In the last line of this page, change: A call to pthread_setspecific() is a request to the Pthreads implementation to say to: A call to pthread_setspecific() is a request to the Pthreads implementation that says Reported by Yaakov Eisenberg. |
2023-06-09 |
672 |
In the second paragraph on this page, change: Precisely what happens to the target thread, and when it happens, depends to: Precisely what happens to the target thread, and when it happens, depend Reported by Yaakov Eisenberg. |
2023-06-09 |
691 |
In the second line of this page, change: process as whole to: process as a whole Reported by Yaakov Eisenberg. |
2023-06-09 |
702 |
The following change applies only to the PDF version of the book. A correction was made in both the printed book and the PDF in print run 6, but that fix was somehow reverted in print run 7. In the third line in the paragraph in the middle of this page, change: If septgid() changes to: If setpgid() changes Reported by Yaakov Eisenberg. |
2023-06-09 |
708 |
In the first sentence of the paragraph just above the prototype box, change: The tcgetpgrp() and tcsetpgrp() functions respectively retrieve and change the process group of a terminal. to: The tcgetpgrp() and tcsetpgrp() functions respectively retrieve and change the foreground process group of a terminal. Reported by Yaakov Eisenberg. |
2023-08-03 |
715 |
In the first sentence of the last paragraph, change: After we typed Control-Z, the shell displays the command that has been stopped in the background. to: After we typed Control-Z, the shell displays the command that has been stopped and moved to the background. Explanation:
Reported by Yaakov Eisenberg. |
2023-08-03 |
716 |
In the small-font note near the top of the page, change: The Korn and C shells provide the command stop as a shorthand for kill –stop. to: The Korn and C shells provide the command stop as a shorthand for kill –STOP. Reported by Yaakov Eisenberg. |
2023-08-03 |
721 |
In the second sentence of the second paragraph, change: We can also see that the new job is in the same session as the shell and that all of the processes are in the same process group. to: We can also see that the new job is in the same session as the shell and that both of its processes are in a single new process group. Explanation:
Reported by Yaakov Eisenberg. |
2023-08-03 |
723 |
In the second line from the top of the page, change: caused one of its child to stop. to: caused one of its children to stop. Reported by Yaakov Eisenberg. |
2023-08-03 |
726 |
In the first sentence of the small-font note near the top of the page, change: By definition, a session leader is in an orphaned process group. to: By definition, a session leader is (initially) in an orphaned process group. Explanation:
Reported by Yaakov Eisenberg. |
2023-08-04 |
730 |
In the last sentence of the second-to-last paragraph, change: If the terminal TOSTOP is set, to: If the terminal's TOSTOP flag is set, Reported by Yaakov Eisenberg. |
2023-08-03 |
736 |
Change the initial sentences of the fourth paragraph: Since kernel 2.6.12, Linux provides the RLIMIT_NICE resource limit, which permits unprivileged processes to raise priorities. An unprivileged process can set its own nice value to the maximum specified by the formula 20 – rlim_cur where rlim_cur is the current RLIMIT_NICE soft resource limit. As an example, if a process’s RLIMIT_NICE soft limit is 25, then its nice value can be set to –5. to: Since kernel 2.6.12, Linux provides the RLIMIT_NICE resource limit, which permits unprivileged processes to raise priorities. An unprivileged process can set its own nice value as low as 20 – rlim_cur where rlim_cur is the current RLIMIT_NICE soft resource limit. As an example, if a process’s RLIMIT_NICE soft limit is 25, then its nice value can be set to –5, but no lower. Explanation:
Reported by Yaakov Eisenberg. |
2023-08-04 |
762 |
In the text following the RLIMIT_NOFILE subheading, change: The RLIMIT_NICE limit (Linux-specific; since Linux 2.6.12) specifies a ceiling on the nice value that may be set for this process using sched_setscheduler() and nice(). The ceiling is calculated as 20 – rlim_cur, where rlim_cur is the current RLIMIT_NICE soft resource limit. to: The RLIMIT_NICE limit (Linux-specific; since Linux 2.6.12) specifies a floor on the nice value that may be set for this process using setpriority() and nice(). The floor is calculated as 20 – rlim_cur, where rlim_cur is the current RLIMIT_NICE soft resource limit. Explanation:
Reported by Yaakov Eisenberg. |
2023-08-04 |
762 |
In the last sentence of the first paragraph following the RLIMIT_NOFILE subheading, change: In most cases, the error is EMFILE, but for dup2(fd, newfd) it is EBADF, and for fcntl(fd, F_DUPFD, newfd) with newfd is greater than or equal to the limit, it is EINVAL. to: In most cases, the error is EMFILE, but for dup2(fd, newfd) it is EBADF and for fcntl(fd, F_DUPFD, newfd) it is EINVAL if newfd is, in either case, greater than or equal to the limit. Reported by Yaakov Eisenberg. |
2023-08-03 |
772 |
In the last sentence of the second paragraph, change: and restart it after (fixing the bug). to: and restart it (after fixing the bug). Reported by Yaakov Eisenberg. |
2023-08-03 |
784 |
In the first sentence of the third paragraph, change: Even in cases where a set-user-ID or set-group-ID is needed, to: Even in cases where a set-user-ID or set-group-ID program is needed, Reported by Yaakov Eisenberg. |
2023-08-03 |
791 |
In the first line of this page, change: from process's effective group ID to: from the process's effective group ID Reported by Yaakov Eisenberg. |
2023-08-05 |
793 |
At the end of the first sentence in the small-font note somewhat more than half-way down the page, change: always appends a null character at the end of the buffer. to: always appends a null character after the copied string. Reported by Yaakov Eisenberg. |
2023-08-05 |
801 |
In the first line of the second column of the CAP_SYS_NICE entry, change: Raise nice value to: Lower nice value, i.e., raise priority Reported by Yaakov Eisenberg. |
2023-08-13 |
808 |
In the last line of this page (in Listing 39-1, cap/check_password_caps.c), change:
to:
|
2024-01-23 |
809 |
About two thirds of the way down this page (in Listing 39-1, cap/check_password_caps.c), change:
to:
|
2024-01-23 |
812 |
In Table 39-2, in the entry for SECBIT_NOROOT, change: If a process with a real or effective user ID of 0 does an exec(), or it execs a set-user-ID-root program, don’t grant it capabilities (unless the executable has file capabilities). to: If a process with a real or effective user ID of 0 does an exec(), or any process execs a set-user-ID-root program, don’t grant capabilities to the process (unless the executable has file capabilities). And near the bottom of the page, change:
to:
Explanation:
Reported by Yaakov Eisenberg. |
2023-08-13 |
824 |
Near the end of Listing 40-2 (loginacct/dump_utmpx.c), change:
to: time_t tv_sec = ut->ut_tv.tv_sec; printf("%s", ctime(&tv_sec)); } endutxent(); Explanation:
Reported by Yaakov Eisenberg. |
2023-08-13 |
829 |
Make two similar changes in Listing 40-3 (loginacct/utmpx_login.c). Near the top of the program, change:
to:
Near the bottom of the page, change:
to:
Explanation:
Reported by Yaakov Eisenberg. |
2023-08-13 |
860 |
In the second sentence in the last paragraph on this page, change the formatting: The library is loaded into memory only once (by the initial call), and all calls return the same handle value. to: The library is loaded into memory only once (by the initial call), and all calls return the same handle value. Reported by Yaakov Eisenberg. |
2023-08-27 |
864 |
In the second paragraph on this page, change: The *(void **) syntax doesn't incur this warning because we are assigning to an address pointed to by the assignment's lvalue. to: The *(void **) syntax doesn't incur this warning because we are are not assigning to the cast expression itself, but rather to the result of dereferencing it. Reported by Yaakov Eisenberg. |
2024-01-09 |
866 |
In the last sentence of the first paragraph on this page, change: An implicit dlclose() of all libraries is performed on process termination. to: An implicit dlclose() of all libraries is performed on normal process termination via exit(). |
2023-12-15 |
871 |
In the second sentence of the paragraph in the middle of this page, change: The first of these directives says that xyz_old() is the implementation of xyz() to be used for applications linked against version tag VER_1 (i.e., program p1 in our example), and that xyz_new() is the implementation of xyz() to be used by applications linked against version tag VER_2. to: The first of these directives says that xyz_old() is the implementation of xyz() to be used for applications linked against version tag VER_1 (i.e., program p1 in our example), and the second says that xyz_new() is the implementation of xyz() to be used by applications linked against version tag VER_2. Reported by Yaakov Eisenberg. |
2024-01-09 |
875 |
Near the middle of this page, change: If desired, we can assign multiple options to LD_DEBUG by separating them with commas (no spaces should appear). to: If desired, we can assign multiple options to LD_DEBUG by separating them with commas, colons, or (if the string is quoted) spaces. |
2023-11-25 |
881 |
In the second-to-last sentence of the second bullet point, change: Because of its limited functionality, flock() locking facility is rarely used nowadays. to: Because of its limited functionality, the flock() locking facility is rarely used nowadays. Reported by Yaakov Eisenberg. |
2024-01-09 |
885 |
In the first bullet point under the heading Accessibility, change: For some IPC facilities (e.g., FIFOs and sockets) to: For some IPC facilities (e.g., FIFOs and UNIX domain sockets) Reported by Yaakov Eisenberg. |
2024-01-09 |
896 |
Near the end of this page (in Listing 44-2, pipes/simple_pipe.c), change: if (close(pfd[0]) == -1) errExit("close"); to:
Explanation:
Reported by Yaakov Eisenberg. |
2024-01-01 |
907 |
In the second sentence of the second-to-last paragraph on this page, change: Generally, the only sensible use of a FIFO is to have a reading process and a writing process on each end. to: Generally, the only sensible use of a FIFO is to have a reading process on one end and a writing process on the other end. Explanation:
Reported by Yaakov Eisenberg. |
2024-01-09 |
920 |
In the fourth line of Exercise 44-6, change: and other client's requests would be indefinitely delayed. to: and other clients' requests would be indefinitely delayed. Reported by Yaakov Eisenberg. |
2024-01-09 |
923 |
In the first sentence of the small-font note near the top of this page, change: In the context of System V IPC, the object doesn't carry any of the connotations associated with object-oriented programming. to: In the context of System V IPC, the term object doesn't carry any of the connotations associated with object-oriented programming. Reported by Yaakov Eisenberg. |
2024-01-09 |
927 |
In the second-to-last paragraph on this page, change: Initially, the corresponding user and creator ID fields have the same values, which are taken from the effective IDs of the calling processes. to: Initially, the corresponding owner and creator ID fields have the same values, which are taken from the effective IDs of the calling process. Reported by Yaakov Eisenberg. |
2024-01-09 |
931 |
In Listing 45-1 (svipc/svmsg_demo_server.c), change:
to:
Reported by Yaakov Eisenberg. |
2024-01-09 |
935 |
About half-way down the page, remove this entire (one-sentence) paragraph: Unlike the ipcs command, these files always show all objects of the corresponding type, regardless of whether read permission is available on the objects. Explanation:
Reported by Yaakov Eisenberg. |
2024-01-09 |
944 |
About half-way down the page, change: Upon successful completion, msgrcv() returns the size of the mtext field of the received message; on error, -1 is returned. to: Upon successful completion, msgrcv() returns the the number of bytes that were copied into the mtext field; on error, -1 is returned. Explanation:
Reported by Yaakov Eisenberg. |
2024-01-09 |
952 |
In the first line of this page, remove this sentence: (The ipcs program employs these operations.) Explanation:
Reported by Yaakov Eisenberg. |
2024-01-09 |
1039 |
In the third paragraph, change: The default value contained in this file is 50, meaning that the kernel can overallocate up to 50% of the size of the system’s RAM, and this will be successful, as long as not all processes try to use their full allocation. to: The default value contained in this file is 50, meaning that the kernel limits allocations to the size of swap space plus 50% of the size of the system’s RAM. Reported by Yaakov Eisenberg. |
2023-01-30 |
1111 |
Towards the end of Listing 54-1 (pshm/pshm_create.c), change: /* Map shared memory object */ addr = mmap(NULL, size, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0); if (addr == MAP_FAILED) errExit("mmap"); to: /* Map shared memory object */ if (size > 0) { addr = mmap(NULL, size, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0); if (addr == MAP_FAILED) errExit("mmap"); } Explanation:
|
2022-12-18 |
1336 |
In the second-to-last shell session log on this page, change: $ ./t_select 0 0r ready = 0 timeout after select(): 0.000 to:
Reported by Joaquín Moreno. |
2024-03-10 |
1372 |
Towards the botton of the page (in Listing 63-9, altio/self_pipe.c), change:
to:
Explanation:
Reported by Sergio García Tapia. |
2024-09-13 |
1480 |
Remove the following index entry: physical block, 253 Explanation:
|
2023-02-25 |
The following fixes and improvements were applied in the fourteenth and later printings of the book.
Page | Fix | Reported |
40 |
In the first bullet point of Section 2.16, change: Universal Coordinated Time to: Coordinated Universal Time Reported by Yaakov Eisenberg. |
2022-08-17 |
186 |
In the first paragraph of Section 10.1, change: Universal Coordinated Time to: Coordinated Universal Time |
2022-08-17 |
189 |
In the second to last paragraph on page 189, change: The tm_sec field can be up to 60 (rather than 59) to account for the leap seconds that are occasionally applied to adjust human calendars to the astronomically exact (the so-called tropical) year. to: The tm_sec field can be up to 60 (rather than 59) to account for the leap seconds that are occasionally applied to account for the difference between the precise International Atomic Time (TAI) and the observed solar time, which is less precise because of factors such as geological events and the gradual slowdown in the earth's rotation. Reported by Yaakov Eisenberg. |
2022-08-22 |
626 |
In listing 29-1 (threads/simple_thread.c), change:
to: static void * threadFunc(void *arg) { char *s = arg; Explanation:
Reported by Alejandro Colomar. |
2021-09-17 |
861 |
Two related changes are required on this page. In the description of the RTLD_GLOBAL flag, change: Symbols in this library and its dependency tree are made available for resolving references in other libraries loaded by this process and also for lookups via dlsym(). to: Symbols in this library and its dependency tree are made available for satisfying subsequent symbol resolution operations in other shared libraries (and in the main program) and also for lookups via dlsym(). In the description of the RTLD_LOCAL flag, change: This is the converse of RTLD_GLOBAL and the default if neither constant is specified. It specifies that symbols in this library and its dependency tree are not available to resolve references in subsequently loaded libraries. to: This is the converse of RTLD_GLOBAL and the default if neither constant is specified. It specifies that symbols in this library and its dependency tree are not available for satisfying subsequent symbol resolution operations in other shared libraries (and in the main program). Explanation:
|
2022-03-29 |
872 |
In the first paragraph on this page, change: Version tag dependencies indicate the relationships between successive library versions. Semantically, the only effect of version tag dependencies on Linux is that a version node inherits global and local specifications from the version node upon which it depends. to: Version tag dependencies indicate the relationships between successive library versions. The dependencies thus help human readers understand the relationship between library versions. However, semantically, the dependencies have no effect on the behavior of either the static linker or the dynamic linker. Explanation:
|
2022-08-31 |
872 |
Replace the entire fourth paragraph on this page:
with the following two paragraphs:
Explanation:
|
2022-09-11 |
1004 |
Near the end of Listing 48-2 (svshm/svshm_xfr_writer.c), change:
to:
|
2022-07-02 |
1113 |
Toward the end of Listing 54-3 (pshm/pshm_read.c), change: if (close(fd) == -1); /* 'fd' is no longer needed */ errExit("close"); to:
Explanation:
|
2021-12-17 |
The following fixes and improvements were applied in the thirteenth and later printings of the book.
Page | Fix | Reported |
54 |
In Listing 3-3 (lib/error_functions.c), change:
to:
Explanation:
Reported by Alejandro Colomar. |
2021-05-16 |
61 |
At the top of the page (in the final part of Listing 3-6, lib/get_num.c), change:
to: return res; Explanation:
Reported by Alejandro Colomar. |
2021-05-18 |
64 |
Near the start of Table 3-1, in the second column of the row that starts dev_t, change: an arithmetic type to: integer Explanation:
|
2020-10-18 |
65 |
Toward the end of Table 3-1, in the second column of the row that starts time_t, change: integer or real-floating to: integer Explanation:
|
2020-10-18 |
116 |
At the end of the first paragraph in the small-font note in the second half of this page, remove the following sentence: Sometimes, the term section is used instead of segment, since section is more consistent with the terminology used in the now ubiquitous ELF specification for executable file formats. Explanation:
Reported by Martin McClure. |
2020-11-24 |
324 |
At the bottom of this page, change: chmod(pathname, 751); to:
Reported by Junjiro Okajima. |
2020-09-02 |
330 |
In the box in the bottom left-hand corner of Figure 17-2, change "acl_type_t" to "acl_tag_t". (This erratum was modified slightly on 2021-08-17, after a note from Claudio Fornaro.) Reported by Andrew McKinlay. |
2020-08-11 |
331 |
In the last sentence on this page, change: The tag_type argument has the type acl_type_t to: The tag_type argument has the type acl_tag_t Reported by Andrew McKinlay. |
2020-08-11 |
896 |
Toward the bottom of the page, change:
to: write(STDOUT_FILENO, "\n", 1); if (close(pfd[0]) == -1) errExit("close"); exit(EXIT_SUCCESS); Explanation:
|
2021-03-26 |
1087 |
Near the end of the small-font note near the top of the page, change: it was not deemed possible to provide to: it was deemed not possible to provide Reported by David Featherstone. |
2021-01-29 |
1113 |
Toward the end of Listing 54-3 (pshm/pshm_read.c), change:
to:
Explanation:
|
2021-03-12 |
1440 |
In the small-font note under the bibliography entry for "Josey, A. (ed.). 2004", change: See http://www.unix-systems.org/version3/theguide.html for details on ordering this guide. to: This guide can be found online at http://www.unix.org/version3/theguide.html. |
2020-11-22 |
The following fixes and improvements were applied in the twelfth and later printings of the book.
Page | Fix | Reported |
71 |
Toward the end of Listing 4-1 (fileio/copy.c), change:
to:
Explanation:
Reported by Hrvoje Nikšić. |
2020-01-14 |
75 |
In the second and third bullet points at the top of the page, change:
to:
Reported by 徐锋. |
2020-06-12 |
84 |
Near the start of the main() function in Listing 4-3 (fileio/seek_io.c) change: int fd, ap, j; char *buf; ssize_t numRead, numWritten; to:
Explanation:
Reported by Philippe Brodeur. |
2019-12-15 |
85 |
In Listing 4-3 (fileio/seek_io.c), about one third of the way down the page, change: for (j = 0; j < numRead; j++) { if (argv[ap][0] == 'r') printf("%c", isprint((unsigned char) buf[j]) ? buf[j] : '?'); else printf("%02x ", (unsigned int) buf[j]); } to: for (j = 0; j < numRead; j++) { if (argv[ap][0] == 'r') printf("%c", isprint(buf[j]) ? buf[j] : '?'); else printf("%02x ", buf[j]); } Explanation:
Reported by Philippe Brodeur, with a fix (s/byte/bit/) to the explanation on 2024-10-15 after a note from Dave Chupreev. |
2019-12-15 |
108 |
In the last sentence of Section 5.11, change: As a convenience, the names /dev/stdin, /dev/stdout, and /dev/stderr are provided as symbolic links to, respectively, /dev/fd/0, /dev/fd/1, and /dev/fd/2. to: As a convenience, the names /dev/stdin, /dev/stdout, and /dev/stderr are provided as symbolic links to, respectively, /proc/self/fd/0, /proc/self/fd/1, and /proc/self/fd/2 (equivalent to /dev/fd/0, /dev/fd/1, and /dev/fd/2). Reported by Ghe Rivero. |
2020-07-02 |
The following fixes and improvements were applied in the eleventh and later printings of the book.
Page | Fix | Reported |
462 |
Near the start of listing 22-3 (signals/catch_rtsigs.c), change:
to:
Explanation:
Reported by Alexander Pozdneev. |
2019-11-21 |
483 |
In the main() function of Listing 23-1 (timers/real_timer.c), change:
to: if (argc > 1 && strcmp(argv[1], "--help") == 0) usageErr("%s [secs [usecs [int-secs [int-usecs]]]]\n", argv[0]); Explanation:
Reported by Cyrus Ramavarapu. |
2019-02-15 |
517 |
In the paragraph at the bottom of the page, change: These duplicates are made in the manner of dup(), which means that corresponding descriptors in the parent and the child refer to the same open file description. to: The duplicated file descriptors in the child refer to the same open file descriptions as the corresponding descriptors in the parent. Explanation:
Reported by Conor O'Rourke. |
2019-01-09 |
906 |
In the last sentence of the second paragraph of Section 44.6, change: If this is a problem, there is little we can do unless we can modify the source code of the program running in the child process to include calls to setbuf() of fflush(). to: If this is a problem, there is little we can do unless we can modify the source code of the program running in the child process to include calls to setbuf() or fflush(). Reported by Kaleem Khan. |
2019-02-04 |
1383 |
Near the top of the page, change: Once we have unlocked the slave device with unlockpt(), we can open it using the traditional open() system call. to: Once we have unlocked the slave device with unlockpt(), we can open it by passing the name returned by ptsname() to the open() system call. Explanation:
Reported by Yuchao Song. |
2019-06-10 |
The following fixes and improvements were applied in the tenth and later printings of the book.
Page | Fix | Reported |
1112 |
Near the end of Listing 54-2 (psh/pshm_write.c), change:
to:
|
2018-08-26 |
1291 |
In the first paragraph of the small-font note at the top of this page, change: On Linux, sysconf(_SC_MAX_INPUT) and sysconf(_SC_MAX_CANON) both return the value 255. to: On Linux, pathconf() returns the value 255 for both of these limits. Reported by Vishnu Bharathi. |
2018-08-20 |
The following fixes and improvements were applied in the ninth and later printings of the book.
Page | Fix | Reported |
vi |
Toward the end of this page, a typographical glitch means that the "Registered Trademark" symbol after the word "UNIX" was incorrectly rendered. The (tiny) characters after "UNIX" need to be replaced by a circled "R". Explanation:
Reported by Alex Pinkney. |
2018-06-21 |
294 |
In the fourth line of code from the top of this page, change:
to:
|
2018-06-19 |
318 |
Towards the end of Listing 16-1 (xattr/xattr_view.c), fix a casting error by changing:
to:
|
2018-05-03 |
361 |
In Listing 18-3 (dirs_links/nftw_dir_tree.c), change: switch (sbuf->st_mode & S_IFMT) { /* Print file type */ case S_IFREG: printf("-"); break; case S_IFDIR: printf("d"); break; case S_IFCHR: printf("c"); break; case S_IFBLK: printf("b"); break; case S_IFLNK: printf("l"); break; case S_IFIFO: printf("p"); break; case S_IFSOCK: printf("s"); break; default: printf("?"); break; /* Should never happen (on Linux) */ } printf(" %s ", (type == FTW_D) ? "D " : (type == FTW_DNR) ? "DNR" : (type == FTW_DP) ? "DP " : (type == FTW_F) ? "F " : (type == FTW_SL) ? "SL " : (type == FTW_SLN) ? "SLN" : (type == FTW_NS) ? "NS " : " "); if (type != FTW_NS) printf("%7ld ", (long) sbuf->st_ino); else printf(" "); printf(" %*s", 4 * ftwb->level, ""); /* Indent suitably */ printf("%s\n", &pathname[ftwb->base]); /* Print basename */ return 0; /* Tell nftw() to continue */ } to: if (type == FTW_NS) { /* Could not stat() file */ printf("?"); } else { switch (sbuf->st_mode & S_IFMT) { /* Print file type */ case S_IFREG: printf("-"); break; case S_IFDIR: printf("d"); break; case S_IFCHR: printf("c"); break; case S_IFBLK: printf("b"); break; case S_IFLNK: printf("l"); break; case S_IFIFO: printf("p"); break; case S_IFSOCK: printf("s"); break; default: printf("?"); break; /* Should never happen (on Linux) */ } } printf(" %s ", (type == FTW_D) ? "D " : (type == FTW_DNR) ? "DNR" : (type == FTW_DP) ? "DP " : (type == FTW_F) ? "F " : (type == FTW_SL) ? "SL " : (type == FTW_SLN) ? "SLN" : (type == FTW_NS) ? "NS " : " "); if (type != FTW_NS) printf("%7ld ", (long) sbuf->st_ino); else printf(" "); printf(" %*s", 4 * ftwb->level, ""); /* Indent suitably */ printf("%s\n", &pathname[ftwb->base]); /* Print basename */ return 0; /* Tell nftw() to continue */ } Explanation:
Reported by Raam sri. |
2017-11-25 |
586 |
In the last sentence of the small-font note near the top of the page, change: In this case, if a signal was delivered to the child in the small time interval before the call to execl(), then the handler would be invoked in the child, after the signal was unblocked by sigprocmask(). to: In this case, if a signal was delivered to the child in the small time interval before the call to execl(), then the handler would be invoked in the child. (By contrast, in the implementation shown in Listing 27-9, there is a small window of time before the execl() call where these signals will be ignored rather than being handled according to the dispositions that were in effect in the caller.) Explanation:
Reported by Romain Vimont. |
2018-01-08 |
720 |
Near the bottom of this page, change:
to:
|
2018-03-16 |
729 |
In the last paragraph of the page, change: As can be seen, both children receive SIGCONT and SIGHUP after the parent exits. to: As can be seen, both children receive SIGCONT and SIGHUP after the parent exits. (The SIGCONT output appears first because the SIGCONT handler interrupted the SIGHUP handler before the latter handler had a chance to print its output.) Explanation:
Reported by Sergey Oskotskiy. |
2017-11-10 |
812 |
In Table 39-2, in the entry for SECBIT_NO_SETUID_FIXUP, change: Don't change capabilities when effective or file-system user IDs are switched between 0 and nonzero values. to: Don't change capabilities when user IDs are switched between 0 and nonzero values (i.e, during the transitions described in Section 39.6). Explanation:
|
2017-12-02 |
915 |
In the second line of the code shown on this page, change:
to: usageErr("%s [seq-len]\n", argv[0]); Explanation:
Reported by Matthew Meffan. |
2017-11-10 |
976 |
In the middle of Listing 47-5, change:
to:
Reported by Matthew Meffan. |
2017-11-19 |
977 |
Somewhat more than half way through Listing 47-6, change:
to:
Reported by Matthew Meffan. |
2017-11-19 |
1050 |
In the middle of this page, change: mlock(*p1, len1); mlock(*p2, len2); /* Actually has no effect */ munlock(*p1, len1); to: mlock(p1, len1); mlock(p2, len2); /* Actually has no effect */ munlock(p1, len1); Reported by Matthew Meffan. |
2017-12-17 |
1082 |
Near the top of Listing 52-7 (pmsg/mq_notify_thread.c), change: #include <mqueue.h> #include <fcntl.h> /* For definition of O_NONBLOCK */ to:
Explanation:
|
2017-12-05 |
1331 |
Toward the bottom of the page, change:
to:
Explanation:
|
2018-03-26 |
The following fixes and improvements were applied in the eighth and later printings of the book.
Page | Fix | Reported |
618 |
In the label of the upward pointing arrow on the left-hand side of Figure 29-1, change: increasing virtual addesses to: increasing virtual addresses Reported by Giannis Tsaraias. |
2016-12-26 |
824 |
Near the end of Listing 40-2 (loginacct/dump_utmpx.c), change:
to:
Explanation:
Reported by LaoK |
2017-06-09 |
831 |
Near the end of Listing 40-4 (loginacct/view_lastlog.c), change:
to:
Explanation:
Reported by LaoK |
2017-06-09 |
922 |
In the first line of this page, change: first appearing in the late 1970s in Columbus UNIX. to: first appearing in the mid-1970s in Columbus UNIX. Explanation:
|
2017-03-21 |
929 |
In the small-font note toward the bottom of the page, change: It is possible to set the permissions on an IPC object so that the owner or creator can no longer use IPC_STAT to obtain the associated data structure containing the object permissions (which means that the object won’t be displayed by the ipcs(1) command described in Section 45.6), although IPC_SET can still be used to change them. to: It is possible to set the permissions on an IPC object so that the owner or creator can no longer use IPC_STAT to obtain the associated data structure containing the object permissions, although IPC_SET can still be used to change them. Explanation:
Reported by Dmitry Safonov. |
2016-10-06 |
934 |
In the second paragraph (just below the shell session showing the output of the ipcs command), change: On Linux, ipcs(1) displays information only about IPC objects for which we have read permission, regardless of whether we own the objects. On some UNIX implementations, ipcs shows the same behavior as on Linux. However, on other implementations, ipcs displays all objects regardless of whether read permission is granted to the user. to: On Linux, ipcs(1) originally used the IPC_STAT ctl operation (Section 45.3), so that it could display information only about IPC objects for which we have read permission, regardless of whether we own the objects. More recent versions of ipcs use the /proc/sysvipc interfaces (Section 45.7), and can display all objects, regardless of permissions. Explanation:
Reported by Dmitry Safonov. |
2016-10-06 |
1308 |
In the the last paragraph on the page change: the left-arrow key generates the 3-character sequence consisting of Escape followed by 0D to: the left-arrow key generates the 3-character sequence consisting of Escape followed by [D |
2017-03-22 |
The following fixes and improvements were applied in the seventh and later printings of the book.
Page | Fix | Reported |
210 |
In the second sentence of exercise 1, change: Assuming that the clock_t value returned by times() is an unsigned 32-bit integer to: Assuming that the clock_t value returned by times() is a signed 32-bit integer Reported by Olivier Blin. |
2015-09-19 |
281 |
In the last line of the third paragraph, change: On Linux, they are exposed by <sys/types.h> if the _BSD_SOURCE macro is defined. to: On Linux, they are exposed by <sys/sysmacros.h>. Explanation:
|
2016-04-20 |
284 |
At the start of Listing 15-1 (files/t_stat.h), change:
to:
Explanation:
|
2016-04-20 |
350 |
In the last sentence of the third paragraph, change: Alternatively, we can size pathname using the PATH_MAX constant to: Alternatively, we can size buffer using the PATH_MAX constant Reported by Olivier Blin. |
2015-09-21 |
489 |
In the last sentence of the small-font note at the bottom of the page, change: and the time spent in the sleep state to: and the time spent in the stopped state Reported by Alexander Jaoshvili. |
2016-08-03 |
570 |
Towards the end of Listing 27-4 (procexec/t_execle.c), change: execle(argv[1], filename, "hello world", (char *) NULL, envVec); to:
Explanation:
Reported by Tobin Harding. |
2016-04-01 |
662 |
In the last line of the prototype box toward the bottom of the page, change: isassociated to: is associated Reported by 맹규호. |
2015-12-18 |
865 |
Toward the end of Listing 42-1 (shlibs/dynload.c), change:
to:
Explanation:
|
2016-05-13 |
1006 |
In the second-to-last line of the first paragraph in Section 48.5, change: depending on the kernel versions to: depending on the kernel version |
2016-03-17 |
1168 |
Make the following changes in Listing 57-3 (sockets/us_xfr_sv.c). At the top of the listing, change:
to: #include "us_xfr.h" #define BACKLOG 5 And change: /* Construct well-known address, bind server socket to it, and make this a listening socket */ if (remove(SV_SOCK_PATH) == -1 && errno != ENOENT) errExit("remove-%s", SV_SOCK_PATH); memset(&addr, 0, sizeof(struct sockaddr_un)); addr.sun_family = AF_UNIX; strncpy(addr.sun_path, SV_SOCK_PATH, sizeof(addr.sun_path) - 1); to:
Explanation:
Reported by Waclaw Kusnierczyk. |
2016-07-25 |
1172 |
In Listing 57-6 (sockets/ud_ucase_sv.c), change: /* Construct server socket address bind socket to it */ if (remove(SV_SOCK_PATH) == -1 && errno != ENOENT) errExit("remove-%s", SV_SOCK_PATH); memset(&svaddr, 0, sizeof(struct sockaddr_un)); svaddr.sun_family = AF_UNIX; strncpy(svaddr.sun_path, SV_SOCK_PATH, sizeof(svaddr.sun_path) - 1); to:
For details, see the erratum for page 1168. |
2016-07-25 |
1222 |
In the second-to-last line in the example program (sockets/is_seqnum_sv.c), change:
to: if (write(cfd, seqNumStr, strlen(seqNumStr)) != strlen(seqNumStr)) Explanation:
|
2016-04-14 |
1231 |
In the prototype box at the bottom of the page, change:
to:
Reported by Matthew Meffan. |
2015-12-05 |
1381 |
In the prototype box shown toward the bottom of this page, change:
to: #define _XOPEN_SOURCE Reported by 맹규호. |
2015-11-20 |
1381 |
In the first of the two bullet points at the bottom of the page, change: change the ownership of the slave to be the same as the effective user ID of the calling process; to: change the ownership of the slave to be the same as the real user ID of the calling process; Reported by 맹규호. |
2015-11-20 |
The following fixes and improvements were applied in the sixth and later printings of the book.
Page | Fix | Reported |
66 |
In the first paragraph of the small-font note in the middle of this page, change: Thus, we could write %zd instead of using %ld plus a cast for these types. to: Thus, we could write %zd instead of using %ld plus a cast for ssize_t, and analogously %zu for size_t. |
2015-03-17 |
80 |
In the prototype box for write(), change: void *buffer to:
|
2014-11-17 |
228 |
Toward the end of Listing 12-1 (sysinfo/procfs_pidmax.c), change: if (argc > 1) { if (write(fd, argv[1], strlen(argv[1])) != strlen(argv[1])) fatal("write() failed"); system("echo /proc/sys/kernel/pid_max now contains " "`cat /proc/sys/kernel/pid_max`"); } to:
Explanation:
Reported by Haiyan Meng. |
2015-05-09 |
239 |
In the sentence following the fflush() prototype box, change: If stream is NULL, fflush() flushes all stdio buffers. to: If stream is NULL, fflush() flushes all stdio buffers that are associated with output streams. |
2015-01-28 |
385 |
In the first shell session shown at the top of the page, change:
to:
Reported by Eric Dickinson. |
2015-01-13 |
407 |
At the bottom of this page, change the text in the prototype box for sigismember() and the sentence immediately following the prototype box as follows:
to:
|
2015-06-15 |
443 |
In the first bullet point on this page, change the second sentence:
to:
Reported by Ulf (Ulfalizer) Magnusson. |
2015-02-01 |
457 |
In the second and third lines of the paragraph starting "SUSv3 requires..." that follows the two bullet points at the top of the page, change: The Linux kernel defines 32 different realtime signals, numbered from 32 to 63. to: The Linux kernel defines 33 different realtime signals, numbered from 32 to 64. |
2015-02-18 |
651 |
A few lines from the top of the page, inside Listing 30-4 (threads/thread_multijoin.c), change: if (thread[idx].state == TS_TERMINATED){ to:
|
2015-01-30 |
808 |
In the small-font note at the top of the page, change the URL: http://freshmeat.net/projects/libcap-ng to: https://people.redhat.com/sgrubb/libcap-ng/ Explanation:
|
2015-02-09 |
1055 |
In the small-font note at the bottom of the page, change:
to:
|
2015-02-04 |
1069 |
Toward the bottom of the page, in Listing 52-2 (pmsg/pmsg_create.c), change:
to:
Explanation:
|
2014-11-05 |
1082 |
In Listing 52-7 (pmsg/mq_notify_thread.c), at the end of threadFunc(), change:
to: free(buffer); } Explanation:
|
2014-12-01 |
1101 |
Change the entire first paragraph:
to:
|
2014-11-10 |
1140 |
In the first item in the numbered list at the bottom of this page, change: 1. The ordinal number of the lock within the set of all locks held for this file. to: 1. The ordinal number of the lock within the set of all locks shown in this file. |
2015-01-21 |
1341 |
About half way down in the code shown on this page, change:
to:
Explanation:
|
2014-11-29 |
The following fixes and improvements were applied in the fifth and later printings of the book.
Page | Fix | Reported |
xliii |
Above the heading Feedback, insert the following text:
|
2014-02-17 |
62 |
Not quite half way down the page, under the description of the _BSD_SOURCE macro, change:
to:
|
2014-01-06 |
90 |
In the first paragraph of Section 5.1, change:
to:
Explanation:
Reported by Christopher Morris. |
2013-11-22 |
90 |
At the beginning of Listing 5-1, change: fd = open(argv[1], O_WRONLY); /* Open 1: check if file exists */ if (fd != -1) { /* Open succeeded */ to:
|
2013-09-16 |
97 |
At the end of the paragraph following the prototype box for dup2(), change:
to:
Explanation:
|
2014-05-30 |
107 |
This erratum consists of two related changes. In the first line of the second paragraph of Section 5.11, change:
to:
Just above the small-font at the foot of the page, insert a new normal-size paragraph:
Explanation:
|
2013-09-20 |
123 |
In the second paragraph, change:
to:
Explanation:
Reported by Yongzhi Pan. |
2013-12-02 |
275 |
In the bullet point at the bottom of the page, change:
to:
Explanation:
|
2013-09-18 |
340 |
The bottommost rectangle in the I-node table should be gray, as are the other two areas between explicitly shown i-nodes further up in the table. |
2013-11-14 |
383 |
In Listing 19-1 (inotify/demo_inotify.c), near the top of the page, change: int main(int argc, char *argv[]) { int inotifyFd, wd, j; char buf[BUF_LEN]; to:
Explanation:
Reported by Matt Wojciak. |
2014-05-21 |
402 |
A 2012-07-02 erratum that was incorporated into the fourth print run unfortunately added a technical error into the text. That erratum read:
The words "from the user that started the program" should be "from the user that owns the executable". However, an even better replacement text is the following:
Thus the entire text of the bullet point should now read:
Reported by Lorenzo Monti |
2014-01-05 |
407 |
In the second prototype box on this page, change: int sigaddset(sigset_t *set, int sig); int sigdelset(sigset_t *set, int sig); to: int sigaddset(const sigset_t *set, int sig); int sigdelset(const sigset_t *set, int sig); Reported by Robert P. J. Day. |
2013-09-24 |
451 |
In the first paragraph, change:
to:
Reported by Vince Manapat. |
2014-01-05 |
476 |
In the prototype box for sigvec(), change: int sigvec(int sig, struct sigvec *vec, struct sigvec *ovec); to:
|
2014-05-21 |
487 |
In Listing 23-2 (timers/timed_read.c), in the line of code fifth from the top of the page, change:
to: numRead = read(STDIN_FILENO, buf, BUF_SIZE); Explanation:
|
2014-06-30 |
487 |
In the first line of Section 23.4.1, change: The sleep() function suspends execution of the calling process to: The sleep() function suspends execution of the calling thread |
2014-04-05 |
539 |
In Exercise 25-1, change:
to:
Explanation:
|
2013-10-24 |
592 |
In the last line on this page (in Listing 28-1, procexec/acct_on.c), change: usageErr("%s [file]\n"); to:
Reported by Liu Jiaming. |
2013-09-13 |
600 |
In the CLONE_NEWUTS row of Table 28-2, change:
to:
Reported by Yongzhi Pan. |
2013-12-20 |
636 |
Near the top of Listing 30-2 (threads/thread_incr_mutex.c), change: static int glob = 0; to:
Explanation:
Reported by Arnaud Frugier. |
2013-12-04 |
673 |
Three lines above the heading for Section 32.3, change:
to:
Reported by Liu Jiaming. |
2013-09-13 |
690 |
In the first bullet point below the heading LinuxThreads deviations from specified behavior, change:
to:
Explanation:
Reported by Yongzhi Pan. |
2013-12-02 |
695 |
In the third line of the second paragraph, change:
to:
Reported by Yongzhi Pan. |
2013-12-02 |
699 |
In the last two paragraphs on the page, change:
to:
Explanation:
|
2014-05-02 |
707 |
About one third of the way down the page, change the second item in the numbered list:
to:
Reported by Liu Jiaming. |
2013-09-17 |
707 |
In the code snippet toward the bottom of the page, change: if (ioctl(fd, TIOCSCTTY) == -1) errExit("ioctl"); to:
Explanation:
Reported by Liu Jiaming. |
2013-11-12 |
730 |
In the first paragraph of Section 34.8, change:
to:
Explanation:
Reported by Marek Mularczyk. |
2014-05-02 |
732 |
In Exercise 34-4, change:
to:
Explanation:
Reported by Li Wenjun. |
2013-09-06 |
737 |
About half-way through the program listing on this page (procpri/t_setpriority.c), change:
to:
Reported by Liu Jiaming. |
2013-09-22 |
740 |
In the second paragraph of Section 35.2.3, change:
to:
|
2013-09-23 |
740 |
In the second line of the third paragraph of Section 35.2.3, change:
to:
Explanation:
Reported by Liu Jiaming. |
2013-09-23 |
778 |
In the second line from the bottom of the page, change:
to:
|
2013-12-20 |
807 |
In the first numbered list in Section 39.7, change:
to:
Explanation:
Reported by Liu Jiaming. |
2013-09-27 |
814 |
At the end of the second bullet point in Section 39.10, add the following text:
Explanation:
|
2013-09-27 |
816 |
Change the entire text of list item 3:
to:
Explanation:
Reported by Liu Jiaming. |
2013-09-27 |
855 |
In the first line of the shell session at the bottom of the page, change:
to: $ gcc -g -c -fPIC -Wall foo.c Reported by Liu Jiaming. |
2013-10-11 |
863 |
About half way down the page, change:
to:
Reported by Liu Jiaming. |
2013-10-13 |
863 |
In the second-to-last paragraph, change:
to:
|
2014-01-02 |
864 |
In the fourth paragraph from the top of the page, change:
to:
|
2014-01-02 |
866 |
In the definition of the Dl_info structure in the bottom half of the page, change:
to:
|
2014-01-15 |
899 |
In the third line of the last paragraph on this page, change:
to:
Explanation:
|
2013-10-30 |
905 |
Near the end of Listing 44-5 (pipes/popen_glob.c), change:
to: printf("pclose() status = %#x\n", (unsigned int) status); Explanation:
Reported by Liu Jiaming. |
2013-10-22 |
917 |
In the code snippet about two thirds of the way down the page, change: int flags; flags = fcntl(fd, F_GETFL); /* Fetch open files status flags */ flags |= O_NONBLOCK; /* Enable O_NONBLOCK bit */ fcntl(fd, F_SETFL, flags); /* Update open files status flags */ to: int flags; flags = fcntl(fd, F_GETFL); /* Fetch open file status flags */ flags |= O_NONBLOCK; /* Enable O_NONBLOCK bit */ fcntl(fd, F_SETFL, flags); /* Update open file status flags */ |
2013-10-31 |
961 |
In Listing 46-9 (svmsg/svmsg_file_client.c) at the region labeled with a circled 5, change:
to: if (resp.mtype == RESP_MT_FAILURE) { printf("%s\n", resp.data); /* Display msg from server */ exit(EXIT_FAILURE); } Explanation:
Reported by Liu Jiaming. |
2013-10-17 |
978 |
In the prototype box for semop() at the bottom of the page, change: unsigned int nsops to: size_t nsops |
2014-05-01 |
980 |
In the prototype box for semtimedop() in the middle of the page, change: unsigned int nsops to: size_t nsops |
2014-05-01 |
987 |
In the text below the heading Example of the effect of SEM_UNDO, change:
to:
Explanation:
Reported by Liu Jiaming. |
2013-10-19 |
1006 |
In the first sentence on this page, change:
to:
Reported by Guilherme Maciel Ferreira. |
2013-09-30 |
1010 |
About three quarters of the way down the page, change: *p = (target - baseaddr); /* Place offset in *p */ to: *p = target - baseaddr; /* Place offset in *p */ Reported by Yongzhi Pan. |
2013-12-02 |
1021 |
In the sentence immediately preceding the heading Memory protection in more detail, change:
to:
Reported by Guilherme Maciel Ferreira. |
2013-10-11 |
1031 |
In the third line from the bottom of the page, change:
to:
Reported by Liu Jiaming. |
2013-10-22 |
1068 |
In the second line, change:
to:
Reported by Robert P. J. Day. |
2013-09-18 |
1082 |
In Listing 52-7 (pmsg/mq_notify_thread.c), at the end of threadFunc(), change:
to: free(buffer); Explanation:
|
2013-11-25 |
1090 |
In the paragraph following the bullet list in Section 53.2, change:
to:
Explanation:
|
2013-09-18 |
1108 |
In the second paragraph, change:
to:
Explanation:
Reported by Robert P. J. Day. |
2013-09-18 |
1109 |
In the small-font note near the bottom of the page, change:
to:
Reported by Liu Jiaming. |
2013-10-25 |
1121 |
Near the top of Listing 55-1 (filelock/t_flock.c), change:
to:
Reported by Liu Jiaming. |
2013-10-25 |
1134 |
In the last sentence of the bullet point at the top of the page, change:
to:
Reported by Liu Jiaming. |
2013-10-27 |
1141 |
In the second line from the top of the page, change:
to:
Reported by Liu Jiaming. |
2013-10-27 |
1143 |
In the second line on page 1143, change:
to:
Reported by Michael Jobs. |
2013-09-05 |
1158 |
In the second line of the fourth paragraph, change: should be specified as NULL and 0, respectively. to: should both be specified as NULL. |
2014-07-24 |
1161 |
In the last line of the last normal-size paragraph on the page, change:
to:
|
2013-11-04 |
1171 |
In Listing 57-5 (sockets/ud_ucase.h), change:
to:
Reported by Liu Jiaming. |
2013-11-01 |
1218 |
In the prototype box for getnameinfo, change: int getnameinfo(const struct sockaddr *addr, socklen_t addrlen, char *host, size_t hostlen, char *service, size_t servlen, int flags); to: int getnameinfo(const struct sockaddr *addr, socklen_t addrlen, char *host, socklen_t hostlen, char *service, socklen_t servlen, int flags); |
2014-05-20 |
1219 |
In the bullet point at the bottom of the page, change:
to:
Reported by Liu Jiaming. |
2013-11-01 |
1223 |
In the shell session at the bottom of the page, change:
to: Trying 127.0.0.1... Reported by Liu Jiaming. |
2013-11-01 |
1235 |
In the second line of the small-font note at the top of the page, change:
to:
Reported by Liu Jiaming. |
2013-11-01 |
1236 |
In the seventh line of the second paragraph in Section 59.16, change:
to:
Reported by Liu Jiaming. |
2013-11-01 |
1242 |
Near the start of Listing 60-3 (sockets/id_echo_cl.c), change:
to: if (argc < 2 || strcmp(argv[1], "--help") == 0) usageErr("%s host msg...\n", argv[0]); Reported by Liu Jiaming. |
2013-11-07 |
1256 |
In the fifth line of the last paragraph, change:
to:
Reported by Jerome Zago. |
2013-08-03 |
1277 |
In the shell session at the bottom of the page, change: $ tcpdump -t -N 'port 55555' to:
Explanation:
Reported by Liu Jiaming. |
2013-11-07 |
1278 |
In the first line of the last paragraph on this page, change:
to:
|
2013-11-11 |
1308 |
In the first paragraph following the heading MIN == 0, TIME == 0 (polling read), change:
to:
Reported by Yongzhi Pan. |
2013-12-02 |
1308 |
In the second paragraph following the heading MIN == 0, TIME == 0 (polling read), change:
to:
Reported by Peter Hurley. |
2014-03-21 |
1308 |
In the first paragraph following the heading MIN > 0, TIME == 0 (blocking read), change:
to:
Reported by Peter Hurley. |
2013-12-02 |
1308 |
In the paragraph following the heading MIN > 0, TIME > 0 (read with interbyte timeout), change:
to:
Explanation:
|
2013-12-02 |
1336 |
Near the end of Listing 63-1 (altio/t_select.c), change:
to: if (pto != NULL) printf("timeout after select(): %ld.%03ld\n", (long) timeout.tv_sec, (long) timeout.tv_usec / 1000); Reported by Liu Jiaming. |
2013-11-11 |
1338 |
In the paragraph immediately below Table 63-2, change:
to:
|
2013-11-08 |
1341 |
Toward the end of Listing 63-2 (altio/poll_pipes.c), change: ready = poll(pollFd, numPipes, -1); /* Nonblocking */ if (ready == -1) errExit("poll"); printf("poll() returned: %d\n", ready); /* Check which pipes have data available for reading */ for (j = 0; j < numPipes; j++) if (pollFd[j].revents & POLLIN) printf("Readable: %d %3d\n", j, pollFd[j].fd); to: ready = poll(pollFd, numPipes, -1); if (ready == -1) errExit("poll"); printf("poll() returned: %d\n", ready); /* Check which pipes have data available for reading */ for (j = 0; j < numPipes; j++) if (pollFd[j].revents & POLLIN) printf("Readable: %3d\n", pollFd[j].fd); Explanation:
Reported by Liu Jiaming. |
2013-11-11 |
1343 |
In the last row of Table 63-6, change: Stream socket peer closed connection or executed shutdown(SHUT_WR) to: Stream socket peer closed connection Explanation:
Reported by Jiefu Xia. |
2014-03-27 |
1360 |
In the first line of the second item of the dashed list in the bottom half of the page (i.e., about two thirds of the way down the page), change:
to:
Reported by Yongzhi Pan. |
2013-12-02 |
1368 |
In Listing 63-7, near the start of the main() function, change:
to:
Reported by Liu Jiaming. |
2013-12-03 |
1370 |
In Listing 63-8, about half way through the listing, change:
to:
Reported by Liu Jiaming. |
2013-12-03 |
1427 |
In the solution to Exercise 10-1, change:
to:
Explanation:
|
2013-11-13 |
1436 |
At the top of the page, in the line labeled 62-1, change:
to:
|
2013-09-29 |
The following fixes and improvements were applied in the fourth and later printings of the book.
Page | Fix | Reported |
52 |
About a quarter of the way through Listing 3-2 (lib/error_functions.h), change: /* This macro stops 'gcc -Wall' complaining that "control reaches to:
|
2012-09-04 |
61 |
In the second sentence of the first paragraph of Section 3.6.1, change:
to:
Reported by Murray McAllister. |
2012-04-30 |
96 |
In the first sentence of the second-to-last paragraph, change:
to:
Explanation:
Reported by Jeffrey Thompson. |
2012-12-18 |
175 |
Completely replace the second small-font paragraph at the top of this page, changing:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-06-30 |
181 |
Replace the first bullet point on this page:
with:
Explanation:
Reported by Junjiro Okajima. |
2012-07-02 |
200 |
In the last sentence of the paragraph that precedes Section 10.4, change:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-07-02 |
225 |
In the third line of the third paragraph from the bottom of the page, change:
to:
Reported by Junjiro Okajima. |
2012-09-27 |
230 |
At the end of the first small-font paragraph at the top of the page, change:
to:
Reported by Ursache Vladimir |
2012-04-26 |
230 |
At the end of the second small-font paragraph at the top of the page, change:
to:
Reported by Ursache Vladimir |
2012-04-26 |
230 |
At the top of Listing 12-2 (sysinfo/t_uname.c), change: #define _GNU_SOURCE to: #ifdef __linux__ #define _GNU_SOURCE #endif Explanation:
|
2013-03-11 |
264 |
Two changes in Table 14-1. In the line for the flag MS_REC, change:
to:
In the line for the flag MS_RELATIME, change:
to:
Explanation:
Reported by Damien Grassart. |
2013-07-17 |
266 |
In the paragraph at the bottom of the page describing MS_REMOUNT, change:
to:
Reported by Junjiro Okajima. |
2012-07-04 |
271 |
In the second sentence of the first paragraph of Section 14.9.1, change:
to:
Explanation:
Reported by Guilherme Maciel Ferreira. |
2013-07-21 |
277 |
In the third bullet point from the top of the page, change:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-07-04 |
292 |
At the bottom of the page, delete this entire sentence:
Explanation:
Reported by Junjiro Okajima. |
2012-07-05 |
305 |
In the shell session near the top of the page, change:
to:
Explanation:
Reported by Liu Jiaming. |
2013-06-05 |
317 |
At the bottom of this page (in Listing 16-1, xattr/xattr_view.c), change:
to: if (optind >= argc) usageError(argv[0]); Reported by Liu Jiaming. |
2013-06-05 |
358 |
In the last line of the page, change:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-07-09 |
362 |
The same typo, where a "1" should be an "l", appears twice on this page. About half way down the page, change:
to:
Further down the page, change:
to:
Reported by Junjiro Okajima. |
2013-04-16 |
367 |
Just over half way down the page, change:
to:
Reported by Junjiro Okajima. |
2012-07-09 |
392 |
In the third line of the paragraph describing SIGLOST, change:
to:
Reported by Simon Durrant. |
2012-12-12 |
441 |
Near the top of of this table, change the entry in the second column for the row SI_USER from:
to:
Explanation:
|
2012-04-20 |
447 |
Remove the fifth bullet point on this page:
Explanation:
Reported by Trevor Woerner. |
2012-09-28 |
447 |
In the second-to-last bullet point on the page, change:
to:
Reported by Murray McAllister. |
2012-05-16 |
457 |
In the third line of the paragraph starting "SUSv3 requires..." that follows the two bullet points at the top of the page, change:
to:
Reported by Trevor Woerner. |
2012-09-30 |
468 |
In the paragraph immediately following the sigwaitinfo() prototype box, change:
to:
Explanation:
Reported by Daniel Zingaro. |
2012-07-20 |
476 |
In the definition of the sigvec structure shown in the middle of the page, change: void (*sv_handler)(); to:
Reported by Li Wenjun. |
2012-09-06 |
477 |
In the second sentence of the second paragraph of Section 22.14, change:
to:
Reported by Murray McAllister. |
2012-05-16 |
477 |
In the second line of the third paragraph from the bottom of the page, change:
to:
(i.e., change a comma to a period.) Reported by Murray McAllister. |
2012-05-16 |
478 |
In the last line of Exercise 22-2, change:
to:
|
2012-09-29 |
484 |
In Listing 23-1 (timers/real_timer.c) in the line marked with a circled 4, change:
to:
Explanation:
Reported by Trevor Woerner. |
2012-09-30 |
492 |
In the second of the two small-font paragraphs in the middle of the page, change the first sentence:
to:
Reported by Junjiro Okajima. |
2012-08-07 |
502 |
Remove an unneeded line from the top of Listing 23-6 (timers/itimerspec_from_str.c). Change:
to: #include <string.h> #include <stdlib.h> |
2013-07-11 |
502 |
In Listing 23-6 (timers/itimerspec_from_str.c), change: void itimerspecFromStr(char *str, struct itimerspec *tsp) { char *cptr, *sptr; cptr = strchr(str, ':'); if (cptr != NULL) *cptr = '\0'; sptr = strchr(str, '/'); if (sptr != NULL) *sptr = '\0'; tsp->it_value.tv_sec = atoi(str); to: void itimerspecFromStr(char *str, struct itimerspec *tsp) { char *dupstr, *cptr, *sptr; dupstr = strdup(str); cptr = strchr(dupstr, ':'); if (cptr != NULL) *cptr = '\0'; sptr = strchr(dupstr, '/'); if (sptr != NULL) *sptr = '\0'; tsp->it_value.tv_sec = atoi(dupstr); Explanation:
Reported by Liu Jiaming. |
2013-07-11 |
503 |
At the end of Listing 23-6 (timers/itimerspec_from_str.c), change: tsp->it_interval.tv_sec = atoi(cptr + 1); tsp->it_interval.tv_nsec = (sptr != NULL) ? atoi(sptr + 1) : 0; } } to:
Explanation:
Reported by Liu Jiaming. |
2013-07-11 |
505 |
In the shell session in the bottom half of the page change five instances of:
to:
Explanation:
Reported by Trevor Woerner. |
2012-10-02 |
513 |
In the first paragraph of this page, change:
to:
Explanation:
Reported by Trevor Woerner. |
2012-10-03 |
516 |
In the second sentence of the second paragraph, change:
to:
Reported by Murray McAllister. |
2012-05-19 |
519 |
In the first line of the last paragraph on the page, change:
to:
Reported by Simon Durrant. |
2012-12-12 |
521 |
In the fourth line from the end of the second bullet point, change:
to:
Reported by Trevor Woerner. |
2012-10-16 |
555 |
Change the second and third sentences of the first paragraph of Section 26.3:
to:
Reported by Murray McAllister. |
2012-05-31 |
600 |
In the CLONE_NEWNET row of Table 28-2, change:
to:
Reported by Renato Westphal. |
2012-06-05 |
604 |
In the second sentence of the first paragraph under the heading for CLONE_THREAD, change:
to:
Reported by Murray McAllister. |
2012-05-31 |
604 |
In the first sentence of the second paragraph under the heading for CLONE_THREAD, change:
to:
Reported by Murray McAllister. |
2012-05-31 |
646 |
At the bottom of the page, add the following small-font note:
Explanation:
Reported by Chia Hao Lo. |
2012-03-07 |
656 |
In the second-to-last bullet point on the page, change:
to:
Reported by Murray McAllister. |
2012-08-20 |
664 |
In the sentence that immediately precedes Listing 31-1, change:
to:
Reported by Junjiro Okajima. |
2012-08-18 |
677 |
At the end of the first bullet point on this page (starting "If no command-line argument is supplied"), add the following text:
Explanation:
Reported by Chia Hao Lo. |
2012-03-07 |
684 |
In the first sentence of Section 33.2.3, change:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-08-18 |
684 |
In the last line of the page, change:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-08-18 |
687 |
Beginning in the third line of the third paragraph, change:
to:
Reported by Murray McAllister. |
2012-09-19 |
687 |
Under the heading Threads and exit(), change:
to:
Explanation:
Reported by Stefan Puiu. |
2013-04-08 |
688 |
In the second line of the third paragraph below the heading One-to-one (1:1) implementations (kernel-level threads), change:
to:
Reported by Murray McAllister. |
2012-09-19 |
691 |
In the third bullet point from the bottom of the page, change:
to:
Reported by Murray McAllister. |
2012-09-19 |
691 |
In the second bullet point from the bottom of the page, change:
to:
|
2012-09-19 |
704 |
In the first line of the second paragraph under the heading Other (obsolete) interfaces…", change:
to:
Reported by Jordi Sanfeliu. |
2013-03-18 |
739 |
In the second sentence of the last paragraph on the page, change:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-08-18 |
743 |
Near the beginning of Listing 35-2 (procpri/sched_set.c) change: if (argc < 3 || strchr("rfo", argv[1][0]) == NULL) to:
Explanation:
Reported by Brian Blumberg. |
2013-03-09 |
752 |
At the end of Exercise 35-3, add the following sentence:
Reported by Trevor Woerner. |
2012-11-23 |
778 |
In the fourth line of the paragraph describing LOG_NDELAY at the top of the page, change:
to:
Reported by Greg Drysdale. |
2012-09-25 |
782 |
In the third paragraph of Section 37.6, change:
to:
Reported by Junjiro Okajima. |
2012-08-21 |
785 |
In the last sentence of the paragraph immediately below the heading Drop privileges permanently when they will never again be required, change:
to:
Reported by Junjiro Okajima. |
2012-08-22 |
799 |
In the first line of the first small-font note, change:
to:
Reported by Trevor Woerner. |
2012-11-29 |
801 |
In Table 39-1, in the entry for CAP_SYS_ADMIN, change:
to:
Explanation:
|
2012-03-03 |
802 |
In the last line of the small-font note near the top of the page, change:
to:
Reported by Junjiro Okajima. |
2012-08-23 |
819 |
In the second paragraph from the bottom of the page, change:
to:
Reported by Junjiro Okajima. |
2012-08-23 |
873 |
In the second sentence of the paragraph immediately following the heading The _init() and _fini() functions, change:
to:
Reported by Murray McAllister. |
2012-11-28 |
892 |
At the start of the third paragraph following the prototype box for pipe(), change:
to:
Reported by Simon Durrant. |
2013-02-12 |
918 |
In Table 44-3, in the table cell that beginning "Write n bytes, change:
to:
Reported by Murray McAllister. |
2012-12-09 |
924 |
In the fourth line of the paragraph half way down the page that begins "For message queues and semaphores", change:
to:
Reported by Junjiro Okajima. |
2012-08-25 |
925 |
At the end of the second bullet point, change:
to:
Reported by Reza Mostafid. |
2012-10-29 |
925 |
Change the subheading in the middle of the page:
to:
|
2012-10-29 |
936 |
In the fourth line of the second paragraph of Section 45.9, change:
to:
Reported by Murray McAllister. |
2012-12-09 |
936 |
In the second line of the paragraph half way down the page that begins "The ipcs command lists", change:
to:
Reported by Junjiro Okajima. |
2012-08-25 |
940 |
In the last sentence of the second paragraph of Section 46.2 (beginning "This definition is really"), change:
to:
Reported by Junjiro Okajima. |
2012-08-26 |
949 |
In the list item under msg_qbytes, change:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-08-26 |
957 |
In the second line of the last item of the bulleted list, change:
to:
Reported by Junjiro Okajima. |
2012-08-26 |
979 |
In the third bullet point on the page change:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-08-26 |
993 |
In the fifth bullet point in Section 47.11, change:
to:
Reported by Junjiro Okajima. |
2012-08-26 |
1021 |
In the second line below the heading Memory protection in more detail, change:
to:
Reported by Murray McAllister. |
2012-12-28 |
1022 |
At the end of the paragraph that follows the heading Alignment restrictions… at the top of the page, change:
to:
Reported by Murray McAllister. |
2012-12-28 |
1040 |
Starting in the second line from the top of the page, change:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-09-05 |
1054 |
In the first line of Section 50.4, change:
to:
Reported by Murray McAllister. |
2012-12-28 |
1058 |
In the third line from the bottom of the page, change:
to:
Reported by Junjiro Okajima. |
2012-09-05 |
1061 |
Change the one-sentence paragraph that precedes Section 51.2:
to:
Explanation:
|
2012-05-11 |
1066 |
In the paragraph just above the heading Removing a message queue, change:
to:
Reported by Murray McAllister. |
2012-12-28 |
1068 |
In the second line of the second bullet point of Section 52.4, change:
to:
Reported by Junjiro Okajima. |
2012-09-05 |
1072 |
In the last line of this page, change:
to:
Reported by Kanak Kshetri. |
2013-03-23 |
1079 |
In the structure definition at the top of the page, change: void *sigev_notify_attributes; /* Really 'pthread_attr_t' */ to:
Reported by Junjiro Okajima. |
2012-09-05 |
1084 |
In a line of the shell session not quite half way down the page, change:
to:
Reported by Junjiro Okajima. |
2012-09-05 |
1090 |
In the second bullet point in Section 53.2, change:
to:
Reported by Junjiro Okajima. |
2012-09-05 |
1091 |
In the third paragraph from the top of the page (beginning "If sem_open()"), change:
to:
Reported by Junjiro Okajima. |
2012-09-05 |
1099 |
In the second bullet point in Section 53.4, change:
to:
Reported by Junjiro Okajima. |
2012-09-05 |
1103 |
In the last sentence of the second paragraph, change:
to:
Reported by Simon Durrant. |
2013-02-12 |
1105 |
In the list item at the top of the page under SEM_VALUE_MAX, change:
to:
Explanation:
|
2012-08-26 |
1108 |
In the first sentence on the page, change:
to:
Reported by Murray McAllister. |
2012-12-28 |
1124 |
In the code snippet about three quarters of the way down the page change: fcntl(fd, cmd, &flockstr); /* Place lock defined by 'fl' */ to:
Reported by Junjiro Okajima. |
2012-09-05 |
1133 |
In the last line of the first bullet point in Section 55.3.3, change:
to:
Reported by Junjiro Okajima. |
2012-09-05 |
1170 |
In the first line of a paragraph about three quarters of the way down the page, change:
to:
Reported by Junjiro Okajima. |
2012-09-05 |
1194 |
In the bullet point starting "Congestion Avoidance and Control", change:
to:
Reported by Junjiro Okajima. |
2012-09-20 |
1203 |
In the third line of the small-font note in the middle of the page, change:
to:
Reported by Junjiro Okajima. |
2012-09-07 |
1214 |
In the definition of the addrinfo structure, change: size_t ai_addrlen; /* Size of structure pointed to by ai_addr */ to:
|
2012-04-15 |
1214 |
In the eighth line from the bottom of the page, change:
to:
Reported by Matthias Rahlf. |
2012-09-03 |
1240 |
In the last sentence of the second paragraph of Section 60.2, change:
to:
Reported by Junjiro Okajima. |
2012-09-07 |
1241 |
In Listing 60-2 (sockets/id_echo_sv.c), change: int main(int argc, char *argv[]) { int sfd; ssize_t numRead; socklen_t addrlen, len; struct sockaddr_storage claddr; char buf[BUF_SIZE]; char addrStr[IS_ADDR_STR_LEN]; if (becomeDaemon(0) == -1) errExit("becomeDaemon"); sfd = inetBind(SERVICE, SOCK_DGRAM, &addrlen); to:
Explanation:
Reported by Steve Griffis. |
2013-02-11 |
1267 |
In the list entry a little more than half way down the page describing the PSH flag, change:
to:
Reported by Gregory Potamianos. |
2012-11-13 |
1284 |
In the second-to-last line on the page, change:
to:
Reported by Junjiro Okajima. |
2012-09-07 |
1319 |
In the caption for Table 62-5, change:
to:
Reported by Junjiro Okajima. |
2012-09-08 |
1326 |
In the second line of the first normal-size paragraph at the top of the page, change:
to:
Reported by Murray McAllister. |
2012-12-30 |
1340 |
In Listing 63-2 (altio/poll_pipes.c), change: pfds = calloc(numPipes, sizeof(int [2])); if (pfds == NULL) errExit("malloc"); pollFd = calloc(numPipes, sizeof(struct pollfd)); if (pollFd == NULL) errExit("malloc"); to: pfds = calloc(numPipes, sizeof(int [2])); if (pfds == NULL) errExit("calloc"); pollFd = calloc(numPipes, sizeof(struct pollfd)); if (pollFd == NULL) errExit("calloc"); |
2013-01-02 |
1342 |
In the first line of the last paragraph on the page, change:
to:
Reported by Junjiro Okajima. |
2012-09-08 |
1363 |
Toward the end of Listing 63-5 (altio/epoll_input.c), change:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-09-10 |
1369 |
In the code segment in the middle of the page that explains the operation of pselect(), change: sigprocmask(SIG_SETMASK, &sigmask, &origmask); ready = select(nfds, &readfds, &writefds, &exceptfds, timeout); sigprocmask(SIG_SETMASK, &origmask, NULL); /* Restore signal mask */ to: pthread_sigmask(SIG_SETMASK, &sigmask, &origmask); ready = select(nfds, &readfds, &writefds, &exceptfds, timeout); pthread_sigmask(SIG_SETMASK, &origmask, NULL); /* Restore signal mask */ Explanation:
Reported by David Majnemer. |
2012-08-18 |
1428 |
In the fourth line of the solution to Exercise 18-1, change:
to:
Reported by Junjiro Okajima. |
2012-09-10 |
1442 |
Under the bibliography entry for "Mochel, P.", change:
to:
Reported by Junjiro Okajima. |
2012-07-04 |
1470 |
Change the index entry:
to:
|
2012-09-20 |
The following fixes and improvements were applied in the third and later printings of the book.
Page | Fix | Reported | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
11 |
In the second paragraph, change:
to:
Explanation:
|
2011-08-04 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
38 |
In the last sentence of the first paragraph in Section 2.12, change:
to:
Reported by Jaewook Yu. |
2011-04-09 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
73 |
Near the end of Listing 4-2, change:
to: fd = open("w.log", O_WRONLY | O_CREAT | O_APPEND, S_IRUSR | S_IWUSR); Explanation:
Reported by Jessica T McKellar. |
2011-05-26 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
74 |
In Table 4-3, move two rows to a different part of the table:
to give the following:
Explanation:
Reported by Madhavan Kasthurirangan. |
2011-09-04 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
93 |
In the prototype box for fcntl() at the top of the page, change:
to:
Explanation:
|
2011-06-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
97 |
About one third of the way down the page (in the paragraph starting "Assuming the normal situation"), change:
to:
Reported by Simon Durrant. |
2011-08-07 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
102 |
At the end of the paragraph second from the bottom of the page, add a sentence:
Explanation:
Reported by Sun Jian. |
2011-06-15 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
104 |
In the small-font at the top of the page, change:
to:
Reported by Sun Jian. |
2011-06-15 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
104 |
In the first line of the small-font note toward the bottom of the page, change:
to:
Explanation:
|
2011-12-11 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
110 |
In the first line of Exercise 5-1, change:
to:
Explanation:
Reported by Sandipan Razzaque. |
2011-12-11 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
136 |
In the last paragraph on this page, change:
to:
Explanation:
Reported by Bill McConnaughey. |
2011-06-28 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
141 |
In the paragraph below the prototype box for malloc(), change:
to:
Explanation:
Reported by Sun Jian. |
2011-04-07 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
142 |
Add a line at the top of Listing 7-1 (memalloc/free_and_sbrk.c):
Explanation:
Reported by Lei Yang. |
2011-07-05 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
148 |
In the first line of the example code near the top of this page, change:
to:
Reported by Sangman Lee. |
2011-04-13 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
154 |
In the second bullet point, change:
to:
|
2012-02-08 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
166 |
In Exercise 8-1, completely replace the text:
with the following text:
Explanation:
Reported by René Thomsen. |
2011-07-14 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
179 |
About two thirds of the way down the page, change:
to:
Reported by Simon Durrant. |
2011-08-12 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
180 |
In the fifth line from the top of the page, change:
to:
Reported by Yang Yang. |
2011-11-30 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
186 |
At the end of the last paragraph on this page, add a sentence:
Explanation:
|
2011-08-12 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
187 |
At the end of the page, add a small-font note as follows:
Explanation:
|
2011-08-12 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
217 |
Starting in the sixth line of the small-font note about one third of the way down the page, change:
to:
Reported by Yongzhi Pan. |
2011-09-20 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
241 |
In the fifth line from the top of the page, change:
to:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
243 |
Two changes in the third paragraph. In the fourth line, change:
to:
In the seventh and eighth lines, change:
to:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
245 |
In the last sentence of the paragraph explaining POSIX_FADV_SEQUENTIAL, change:
to:
Reported by Simon Durrant. |
2011-08-23 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
252 |
In the second bullet point half-way down the page, change:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
258 |
In the "Key" box in the upper right hand corner of Figure 14-2, change:
to:
Reported by Yongzhi Pan. |
2011-09-20 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
265 |
In the paragraph near the top of the page describing MS_BIND, change:
to:
|
2011-04-02 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
265 |
In the paragraph in the middle of the page describing MS_MOVE, change the last sentence:
to:
Reported by Sangman Lee. |
2011-04-02 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
273 |
In the sentence immediately preceding Section 14.9.5, change:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
278 |
In the third line from the bottom of the page, change:
to:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
280 |
In the third line of the small-font note at the bottom of the page, change:
to:
Reported by Simon Durrant. |
2011-08-23 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
280 |
At the end of the small-font note at the bottom of the page (after the sentence beginning "On Linux, lstat() returns…"), add the following sentence:
|
2011-09-30 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
286 |
In Table 15-2, in the entry for truncate(), change:
to:
Explanation:
|
2012-02-14 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
287 |
In the sentence immediately preceding heading 15.2.1, change:
to:
Reported by Yongzhi Pan. |
2011-09-20 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
290 |
In the prototype box for futimens() at the bottom of the page change:
to:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
297 |
Add some words to the last sentence in the small-font note at the top of the page:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
306 |
In the first line on the page, change:
to:
Reported by Douglas Luu. |
2011-11-12 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
313 |
In the first sentence of the paragraph that precedes the bulleted list in Section 16.2, change:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
331 |
In the second paragraph under the heading Retrieving entries from an in-memory ACL, change the last sentence:
to:
Reported by Yongzhi Pan. |
2011-09-20 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
334 |
In the first sentence of the small-font note near the top of the page, change:
to:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
336 |
About one third of the way down the page, change:
to:
Reported by René Thomsen. |
2011-08-11 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
381 |
In the third line of the paragraph near the top of the page that starts "The cookie field…", change:
to:
|
2011-12-08 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
381 |
Add a sentence at the end of the paragraph near the top of the page that starts "The cookie field…":
Explanation:
Reported by Yang Yang. |
2011-12-06 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
381 |
In the third paragraph from the bottom of the page (starting "Using a larger buffer size"), change:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
392 |
In the third line of the paragraph describing SIGLOST, change:
to:
Reported by Suse Shi. |
2011-04-22 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
404 |
In the paragraph just above the heading for Section 20-7, change:
to:
Explanation:
|
2011-05-18 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
405 |
In Listing 20-3 (signals/t_kill.c), change:
to:
Explanation:
Reported by Madhavan Kasthurirangan. |
2011-05-18 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
407 |
In the first sentence below the prototype box for sigemptyset() and sigfillset(), change:
to:
Reported by Bill McConnaughey. |
2011-07-18 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
408 |
In the last line of the prototype box at the top of the page, change:
to:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
428 |
In the first paragraph of Section 21.1.3, in the third line from end of the paragraph, change:
to:
Explanation:
Reported by Yang Yang. |
2011-12-09 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
457 |
In the second line of the last paragraph on this page, change:
to:
|
2011-12-12 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
458 |
Replace the first two paragraphs on this page:
with:
Explanation:
Reported by Yang Yang. |
2011-12-12 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
460 |
In the second paragraph from the top of the page, change the second sentence:
to:
Explanation:
Reported by Sangman Lee. |
2011-04-02 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
463 |
At the end of Listing 22-3 (signals/catch_rtsigs.c), change: while (!allDone) /* Wait for incoming signals */ pause(); } to:
Explanation:
Reported by Yang Yang. |
2011-12-12 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
469 |
At the top of the page, insert a small-font note as follows:
|
2011-12-08 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
472 |
In the definition of the struct signalfd_siginfo structure, change:
to:
Explanation:
Reported by Sangman Lee. |
2011-05-12 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
476 |
In the prototype box at the bottom of the page, change:
to: int sigmask(int sig); Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
481 |
In the third paragraph, change:
to:
Explanation:
Reported by Sangman Lee. |
2011-04-02 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
482 |
In the fourth line from the top of the page, change:
to:
Reported by Kiju Kim. |
2012-02-15 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
491 |
About two thirds of the way down the page, in the paragraph beginning "The time value", change the last sentence in the paragraph:
to:
Explanation:
Reported by Bill McConnaughey. |
2011-08-12 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
496 |
In the definition of the sigevent structure in the middle of the page, change: pid_t _tid; /* ID of thread to be signaled / to:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
497 |
Add a sentence under the description of SIGEV_THREAD_ID; change:
to:
|
2011-07-19 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
516 |
In the second paragraph from the bottom of the page, change:
to:
Reported by Bill McConnaughey. |
2011-07-18 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
521 |
In the last line of the first bullet point at the top of the page, change:
to:
Reported by Madhavan Kasthurirangan. |
2011-09-04 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
530 |
In Exercise 24-3, change:
to:
Explanation:
Reported by Bill McConnaughey. |
2011-07-18 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
535 |
In the first normal-size paragraph at the top of the page, change:
to:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
555 |
In Listing 26-4 (procexec/make_zombie.c), change:
to: default: /* Parent */ sleep(3); /* Give child a chance to start and exit */ snprintf(cmd, CMD_SIZE, "ps | grep %s", basename(argv[0])); system(cmd); /* View zombie child */ Explanation:
Reported by Madhavan Kasthurirangan. |
2011-09-02 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
565 |
In the explanation of ETXTBSY, change:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
572 |
In the fifth line of the first paragraph of the small-font note on this page, change:
to:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
572 |
In the fourth line of the second paragraph of the small-font note on this page, change:
to:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
580 |
In the third of the bullet points at the top of the page, change:
to:
Explanation:
Reported by Yang Yang. |
2011-12-23 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
601 |
In the second bullet point on this page, at the end of the first sentence ("If CHILD_SIG is nonzero…"), add a circled "5" as a reference to the corresponding line in Listing 28-3. Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
623 |
Inside the prototype box for pthread_exit(), change: include <pthread.h> to:
Reported by Fabien Galand. |
2011-07-13 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
624 |
Inside the prototype boxes for pthread_self() and pthread_equal() (i.e., two changes!), change: include <pthread.h> to:
Reported by Fabien Galand. |
2011-07-13 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
625 |
Inside the prototype box for pthread_join(), change: include <pthread.h> to:
Reported by Fabien Galand. |
2011-07-13 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
632 |
Near the top of Listing 30-1 (threads/thread_incr.c), change: static int glob = 0; static void * /* Loop 'arg' times incrementing 'glob' */ threadFunc(void *arg) to: static volatile int glob = 0; /* "volatile" prevents compiler optimizations of arithmetic operations on 'glob' */ static void * /* Loop 'arg' times incrementing 'glob' */ threadFunc(void *arg) Explanation:
Reported by Yang Yang. |
2011-12-25 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
635 |
In the sentence that immediately precedes Section 30.1.1, change:
to:
Explanation:
Reported by Bill McConnaughey. |
2011-07-18 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
638 |
In the second-to-last line on the page, remove the extra space between the words "early" and "futex". Reported by Fabien Galand. |
2011-11-26 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
644 |
In the seventh line of the second paragraph, change:
to:
Reported by Simon Durrant. |
2011-09-26 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
649 |
This erratum makes changes on pages 649 and 650 to fix a single problem in Listing 30-4 (threads/thread_multijoin.c). On page 649, in the second line from the bottom of the page, change: int idx = *((int *) arg); to:
On page 650, about two thirds of the way down the page, change:
to:
Explanation:
Reported by Jacob Mandelson. |
2011-04-02 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
656 |
In the second paragraph from the top of the page, change:
to:
Reported by Sun Jian. |
2011-09-05 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
674 |
In the shell session toward the bottom of the page, change:
to: $ ./thread_cancel Reported by Yang Yang. |
2011-12-28 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
704 |
In the last line of the prototype box for getsid() at the bottom of the page, change:
to:
Explanation:
|
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
705 |
In the last line of the prototype box for setsid() at the top of the page, change:
to:
Explanation:
|
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
734 |
Change the last sentence on the page:
to:
Explanation:
Reported by Bill McConnaughey. |
2011-07-18 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
736 |
Change the third paragraph:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
736 |
Change the initial sentences of the fourth paragraph:
to:
Explanation:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
741 |
Change the last sentence of the second paragraph:
to:
Reported by Junjiro Okajima. |
2012-01-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
750 |
In the code snippet near the top of the page, change:
to:
Explanation:
Reported by Emmanuel Gras. |
2011-10-14 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
774 |
In Listing 37-3 (daemons/daemon_SIGHUP.c), change:
to: static volatile sig_atomic_t hupReceived = 0; /* Set nonzero on receipt of SIGHUP */ static void sighupHandler(int sig) { Explanation:
Reported by Simon Durrant. |
2011-10-04 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
774 |
This change spans the code at the bottom of page 774 and top of page 775. Change the lines:
to:
Explanation:
Reported by Yacine Belkadi. |
2011-04-19 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
776 |
At the bottom of the page, after the small-font note beginning "Although syslog(2) and syslog(3) share the same name", add a further small-font paragraph:
Reported by Przemysław Pawełczyk. |
2011-06-12 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
814 |
In the second bullet point in Section 39.10, change:
to:
|
2011-09-17 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
827 |
In the prototype box at the top of the page, change: void updwtmpx(char *wtmpx_file, struct utmpx *ut); to: void updwtmpx(const char *wtmpx_file, const struct utmpx *ut); Reported by Yang Yang. |
2012-01-23 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
857 |
Change the first sentence under the heading Further information:
to:
Explanation:
Reported by Yang Yang. |
2012-01-27 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
879 |
In the fourth line from the bottom of the page, change:
to:
Reported by Yang Yang. |
2012-01-28 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
885 |
In the first bullet point at the top of the page, change:
to:
Explanation:
Reported by Yang Yang. |
2012-01-28 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
904 |
In Listing 44-5 (pipes/popen_glob.c), at the bottom of the page, change:
to: /* Build and execute command to glob 'pat' */ snprintf(popenCmd, PCMD_BUF_SIZE, POPEN_FMT, pat); fp = popen(popenCmd, "r"); Explanation:
|
2011-09-02 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
907 |
About one third of the way down the page (three lines above the mkfifo() prototype box), change:
to:
Reported by Fabien Galand. |
2011-11-26 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
916 |
In the first line of the second bullet point at the top of the page, change:
to:
Reported by Yang Yang. |
2012-02-02 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1008 |
In the shell session output at the top of the page, change:
to: $ ./svshm_create -p 102400 9633796 $ ./svshm_create -p 3276800 9666565 Explanation:
Reported by Fabien Galand. |
2011-11-26 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1040 |
In the second paragraph of Section 49.10 (i.e., nearly two thirds of the way down the page), change:
to:
Reported by Fabien Galand. |
2011-11-26 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1042 |
In the code snippet about half way down the page, change: remap_file_pages(addr, ps, 0, 2, 0); /* Maps page 0 of file into page 2 of region */ remap_file_pages(addr + 2 * ps, ps, 0, 0, 0); /* Maps page 2 of file into page 0 of region */ to: remap_file_pages(addr, ps, 0, 2, 0); /* Maps page 2 of file into page 0 of region */ remap_file_pages(addr + 2 * ps, ps, 0, 0, 0); /* Maps page 0 of file into page 2 of region */ Reported by Madhavan Kasthurirangan. |
2011-09-18 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1049 |
In the third line of the second-to-last paragraph (beginning "The munlock() system call…"), change:
to:
Reported by Simon Durrant. |
2011-12-13 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1079 |
In the last line of the paragraph describing, SIGEV_NONE, change:
to:
Reported by Bill McConnaughey. |
2011-07-18 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1141 |
A bit more than half way down the page, change: $ ls -li /dev/sda7 | awk '$6 == "3," && $7 == 10' to:
Explanation:
Reported by Corentin Chary and Gerald Demitre |
2012-01-14 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1161 |
At the start of the third paragraph, change:
to:
Reported by Simon Durrant. |
2011-12-13 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1189 |
In the second paragraph on this page, change:
to:
Explanation:
Reported by Yang Firo. |
2011-05-04 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1190 |
In the right-hand "TCP endpoint" box in Figure 58-8, the boxes labeled "send buffer" and "receive buffer" should be reversed, so that "receive buffer" is at the top and "send buffer" is at the bottom. Reported by Yongzhi Pan. |
2012-01-15 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1203 |
In the first line of the first paragraph, change:
to:
Reported by Simon Durrant. |
2012-01-02 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1214 |
At the end of the ninth line from the bottom of the page, change:
to:
Reported by Simon Durrant. |
2012-01-02 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1230 |
In Listing 59-9 (sockets/inet_sockets.c), near the end of the listing, change:
to: if (getnameinfo(addr, addrlen, host, NI_MAXHOST, service, NI_MAXSERV, NI_NUMERICSERV) == 0) snprintf(addrStr, addrStrLen, "(%s, %s)", host, service); else snprintf(addrStr, addrStrLen, "(?UNKNOWN?)"); return addrStr; Explanation:
|
2011-09-02 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1235 |
In the last line of the first paragraph in Section 59.14, change:
to:
Reported by Simon Durrant. |
2012-01-02 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1261 |
In the small-font note near the bottom of the page, change:
to:
|
2011-09-11 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1337 |
In the first sentence after the poll() prototype box, change:
to:
Reported by Simon Durrant. |
2012-01-02 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1349 |
Just over half way down the page, change:
to:
Explanation:
Reported by Yacine Belkadi. |
2011-04-19 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1355 |
In the fourth line from the top of the page, change:
to:
Reported by Bill McConnaughey. |
2011-07-18 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1361 |
In the shell session in the middle of this page, change: $ fg ./epoll_input p q About to epoll_wait() Ready: 2 fd=4; events: EPOLLIN read 4 bytes: ppp fd=5; events: EPOLLIN EPOLLHUP read 4 bytes: qqq closing fd 5 About to epoll_wait() to:
Explanation:
Reported by Pedro Dominguez. |
2011-04-28 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1361 |
Change the second-to-last paragraph on the page:
to:
Explanation:
|
2011-04-28 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1366 |
In the code snippet a bit more than half way down the page, change: if (epoll_ctl(epfd, EPOLL_CTL_ADD, fd, ev) == -1) to:
Reported by tjuer. |
2011-12-16 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1418 |
At the end of the last paragraph on this page, add a sentence:
Explanation:
Reported by Bill McConnaughey. |
2011-07-18 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1426 |
In the solution for Exercise 8-1, change:
to:
Explanation:
Reported by René Thomsen. |
2011-07-14 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1439 |
Under the bibliography entry for "Gont, F. 2008", change the URL:
to:
Reported by Kiju Kim. |
2012-01-20 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1439 |
Under the bibliography entry for "Gont, F. 2009 (a)", change the URL:
to:
Reported by Kiju Kim. |
2012-01-20 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1440 |
Under the bibliography entry for "Hallyn, S. 2007", change the URL:
to:
Reported by Kiju Kim. |
2012-01-20 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1440 |
In the small-font note under the bibliography entry for "Josey, A. (ed.). 2004", change:
to:
Reported by Kiju Kim. |
2012-01-20 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1440 |
Under the bibliography entry for "Kent, A., and Mogul, J.C. 1987", change the URL:
to:
Reported by Kiju Kim. |
2012-01-20 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1441 |
Under the bibliography entry for "Lu, H.J. 1995" replace the URL:
to:
Explanation:
Reported by Kiju Kim. |
2012-01-20 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1444 |
Under the bibliography entry for "Stone, J., and Partridge, C. 2000", change the URL:
to:
Reported by Kiju Kim. |
2012-01-20 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1469 |
Change the index entry:
to:
Explanation:
|
2011-08-04 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1470 |
Change the index entry:
to:
Explanation:
|
2011-08-04 |
The following fixes and improvements were applied in the second and later printings of the book.
Page | Fix | Reported |
xli |
Under the heading Web site and source code of example programs, change:
to:
|
2011-01-08 |
xli |
Under the heading Feedback, following the sentence:
add the sentence:
|
2011-01-08 |
15 |
In the paragraph just above the heading Legacy features, change:
to:
Explanation:
|
2011-02-28 |
16 |
On the fourth line from the bottom of the page, remove the superfluous right parenthesis following "mid-1990s". Reported by Justin Pryzby. |
2010-12-28 |
32 |
In the fourth paragraph, change:
to:
Reported by Sun Jian. |
2011-02-25 |
48 |
In the fourth line, change:
to:
Reported by Richard Moore. |
2011-01-26 |
57 |
In the first line of text below the example program, change:
to:
Reported by Kiju Kim. |
2011-02-13 |
57 |
In the third line of the second normal-size font paragraph on the page (i.e., a bit more than half way down the page), change:
to:
Reported by Subu Rama. |
2010-12-03 |
67 |
A bit more than half way down the page, immediately following the heading Using macros that may not be present on all implementations change:
to:
Reported by Markus Boje. |
2010-11-22 |
75 |
In the first bullet point at the top of the page, change:
to:
Explanation:
Suggested from a conversation with Krzysztof Żelechowski. |
2010-12-16 |
75 |
In the third line of the O_CLOEXEC paragraph at the bottom of the page, change:
to:
Reported by Subu Rama. |
2010-11-30 |
83 |
In the middle of the last paragraph (small-font note), change:
to:
Explanation:
Reported by Kiju Kim. |
2011-03-19 |
99 |
In the paragraph at the bottom of the page, change:
to:
Reported by Subu Rama. |
2010-11-30 |
110 |
(Exercise 5-3) In the first sentence of the last paragraph on the page, change:
to:
Reported by Justin Pryzby. |
2010-12-28 |
111 |
In Exercise 5-6, change the line: write(fd2, "world", 6); to:
(i.e., add a space before world). Reported by John Wiersba. (I initially wrote up this erratum incorrectly; fixed on 2010-12-07, after a note from Geoff Clare.) |
2010-11-30 |
115 |
In the last paragraph of Section 6.2, change:
to:
(i.e., make the second "P" upper case). Reported by Subu Rama. |
2010-12-20 |
118 |
About one third of the way down the page, change:
to: extern char etext, edata, end; /* For example, &etext gives the address of the next byte past the end of the program text / start of initialized data */ Explanation:
Reported by Sun Jian. |
2011-02-16 |
155 |
In the last paragraph of Section 8.2, change the sentence:
to:
Explanation:
Reported by John Wiersba. |
2010-12-13 |
156 |
In the bullet point for Encrypted password ID about one third of the way down the page, change:
to:
Reported by Justin Pryzby. |
2010-12-28 |
156 |
In the bullet point for Group ID about half way down the page, change the sentence:
to:
Explanation:
Reported by John Wiersba. |
2010-12-13 |
180 |
In the third paragraph, change:
to:
Reported by Justin Pryzby. |
2011-01-03 |
187 |
In the third line of the small-font note about two thirds of the way down the page, change:
to:
|
2010-12-26 |
199 |
In the final paragraph, change the opening piece of the first sentence:
to:
Explanation:
Suggested from a conversation with Subu Rama. |
2010-12-20 |
200 |
About a quarter of the way down the page, add a closing quote at the end of the first code snippet, so that it reads:
Reported by Subu Rama. |
2010-12-20 |
204 |
In the last line of the page, change "4.3BSD" to "4.2BSD". Reported by Roger M. Levasseur. |
2010-12-26 |
262 |
In Figure 14-4, the arrow pointing from Mount points to the windows icon should point instead to the C icon. Reported by Dave Walker. |
2010-11-28 |
276 |
In the first sentence of the bullet point at the bottom of the page, change:
to:
Reported by Subu Rama. |
2011-01-04 |
280 |
Near the end of the small-font note at the bottom of the page, change:
to:
Explanation:
Reported by Justin Pryzby. |
2010-12-28 |
307 |
In the last line of the paragraph for FS_NOTAIL_FL, change:
to:
Reported by Justin Pryzby. |
2010-12-28 |
324 |
In the first bullet point, about half way down the page, change:
to:
Reported by Jorge Merlino. |
2011-03-08 |
353 |
Below the prototype box for readdir() (about half way down the page), change:
to:
Reported by Subu Rama. |
2011-01-12 |
354 |
In the second line, change:
to:
Suggested by a report by Justin Pryzby. |
2010-12-28 |
354 |
At the end of the small-font note near the top of the page, add a sentence:
Reported by Geoff Clare. |
2010-12-31 |
360 |
Near the top of the page, change:
to:
Reported by Subu Rama. |
2011-01-12 |
378 |
Two changes associated with the description of inotify_rm_watch(). 1. In the prototype box at the top of the page, change the line: int inotify_rm_watch(int fd, uint32_t wd); to: int inotify_rm_watch(int fd, int wd); 2. In the paragraph below the prototype box, remove the sentence:
Explanation:
|
2010-10-25 |
387 |
Change the opening sentence on this page:
to:
|
2011-01-03 |
387 |
In the fourth bullet point, change:
to:
Explanation:
|
2011-01-03 |
408 |
In the prototype box at the top of the page, change the line: int sigandset(sigset_t *set, sigset_t *left, sigset_t *right); to: int sigandset(sigset_t *dest, sigset_t *left, sigset_t *right); Reported by Matias Virsu. |
2010-12-22 |
419 |
Change the text of Exercise 20-4:
to:
Explanation:
Reported by Subu Rama. |
2011-01-14 |
431 |
In the shell session about one quarter of the way down the page, change the second line:
to: $ ./sigmask_siglongjmp Explanation:
Reported by Subu Rama. |
2011-01-14 |
439 |
Near the top of the page, in the paragraph under si_code, change:
to:
Reported by Subu Rama. |
2011-01-14 |
468 |
In the prototype box, change:
to:
Explanation:
|
2011-01-03 |
468 |
At the end of the second-to-last paragraph, change:
to:
|
2011-01-04 |
471 |
In the prototype box near the top of the page, change:
to:
Explanation:
|
2011-01-03 |
477 |
In the first line of Section 22.14, change:
to:
Explanation:
Reported by Justin Pryzby. |
2010-12-28 |
480 |
In the paragraph in the middle of the page beginning "The default disposition", change:
to:
Reported by Eric Arora. |
2011-01-05 |
480 |
In the sixth line from the bottom of the page, change:
to:
Reported by Eric Arora. |
2011-01-05 |
483 |
This fix applies to a segment of code that spans the bottom of page 483 and the top of page 484. The change moves a block of code to a location lower down in the program (but otherwise leaves the lines of code unchanged). Change:
to:
Explanation:
Reported by Subu Rama. |
2011-01-17 |
538 |
In the second bullet point, half way down the page, change:
to:
Explanation:
Suggested by a conversation with Justin Pryzby. |
2011-01-03 |
574 |
In the last line of the small-font note at the top of the page (starting "The Linux 2.2 kernel…"), change:
to:
Reported by Subu Rama. |
2011-01-27 |
585 |
In the second-to-last line of the first bulleted paragraph on the page, change:
to:
Explanation:
Reported by Justin Pryzby. |
2010-12-28 |
617 |
In the last line of the page, change:
to:
Reported by Subu Rama. |
2011-01-27 |
618 |
In the second paragraph on the page (starting "The threads in a process"), change the second sentence:
to:
Reported by Eric Arora. |
2011-01-05 |
618 |
In the second paragraph on the page (starting "The threads in a process"), change:
to:
Reported by Subu Rama. |
2011-01-27 |
621 |
In the code segment at the bottom of the page, change:
to: pthread_t thread; Reported by Subu Rama. |
2011-02-17 |
624 |
In the sentence just above the box containing the prototype for pthread_equal(), change:
to:
Reported by Jens Thoms Toerring. |
2011-02-27 |
642 |
In the fourth line from the top of the page, change: s = pthread_mutex_init(mtx, &mtxAttr); to:
Reported by Gary Hu. |
2011-01-05 |
668 |
About half way down the page, change: static __thread buf[MAX_ERROR_LEN]; to:
Reported by Sangman Lee. |
2011-03-09 |
702 |
In the middle of the page, change this entire paragraph:
to:
Explanation:
Reported by Jonathan Nieder. |
2011-02-16 |
708 |
In the second line of Section 34.5, change:
to:
Reported by Justin Pryzby. |
2010-12-28 |
730 |
Two changes in the first paragraph of Section 34.8. 1. Change:
to:
2. Change:
to:
The first of these changes was suggested by Justin Pryzby. |
2011-01-03 |
740 |
In the first and third bullet points (i.e., two changes) in Section 35.2.2, change:
to:
Reported by Sangman Lee. |
2011-03-11 |
760 |
In the second line of the small-font note about a third of the way down the page, change:
to:
Reported by Justin Pryzby. |
2010-12-28 |
769 |
In the third line from the bottom of the page, change:
to:
Reported by Justin Pryzby. |
2010-12-28 |
780 |
In the code snippet at the top of the page, change the line:
to: syslog(LOG_ERR, "Bad argument: %s", argv[1]); Reported by Greg Olin. |
2010-12-06 |
785 |
In the code segment at the bottom of the page, change two instances of: if (setuid(getuid() == -1) to:
Reported by Sangman Lee. |
2011-03-16 |
786 |
In the fourth line of text, change:
to:
Explanation:
Reported by Przemysław Pawełczyk. |
2010-11-28 |
786 |
Add a sentence to the end of the third paragraph:
Explanation:
Reported by Geoff Clare. |
2010-12-07 |
822 |
In the second line of the second bullet point (in the middle of the page), change:
to:
Reported by Sangman Lee. |
2011-03-16 |
849 |
Change the shell command in line 9:
to: # ls -l libdemo* | awk '{print $1, $9, $10, $11}' Reported by Zerksis Umrigar. |
2010-12-25 |
895 |
In the seventh line from the bottom of the page, change:
to:
Reported by Sangman Lee. |
2011-03-16 |
1017 |
In the first line of the small-font note at the bottom of the page, change:
to:
Reported by Justin Pryzby. |
2010-12-28 |
1083 |
In the second of the three bullet points in the middle of the page, change:
to:
Reported by Subu Rama. |
2011-02-17 |
1102 |
In the first comment of the main() function in Listing 53-6 (psem/thread_incr_psem.c), change:
to:
Reported by Subu Rama. |
2011-02-17 |
1119 |
In the third line from the bottom of the page, change:
to:
Reported by Justin Pryzby. |
2010-12-28 |
1176 |
At the end of the first paragraph, change these entire sentences:
to:
Explanation:
|
2010-10-25 |
1176 |
In Listing 57-8 (sockets/us_abstract_bind.c), change /* addr.sun_path[0] has already been set to 0 by memset() */ strncpy(&addr.sun_path[1], "xyz", sizeof(addr.sun_path) - 2); /* Abstract name is "xyz" followed by null bytes */ sockfd = socket(AF_UNIX, SOCK_STREAM, 0); if (sockfd == -1) errExit("socket"); if (bind(sockfd, (struct sockaddr *) &addr, sizeof(struct sockaddr_un)) == -1) errExit("bind"); to: /* addr.sun_path[0] has already been set to 0 by memset() */ str = "xyz"; /* Abstract name is "\0xyz" */ strncpy(&addr.sun_path[1], str, strlen(str)); sockfd = socket(AF_UNIX, SOCK_STREAM, 0); if (sockfd == -1) errExit("socket"); if (bind(sockfd, (struct sockaddr *) &addr, sizeof(sa_family_t) + strlen(str) + 1) == -1) errExit("bind"); Explanation:
|
2010-10-25 |
1192 |
In the eighth line of the paragraph headed Flow control, change:
to:
Reported by Subu Rama. |
2011-02-17 |
1218 |
In the last sentence of the paragraph somewhat more than half way down the page starting "The resulting host and service names…", change:
to:
Reported by Subu Rama. |
2011-02-17 |
1247 |
In the fifth and sixth lines of the third paragraph (beginning "One of the simplest approaches…"), change:
to:
Explanation:
|
2011-01-06 |
1247 |
In the fourth paragraph (beginning "Round-robin DNS has the advantage…"), change the second and third sentences:
to:
Explanation:
Suggested from a conversation with Justin Pryzby. |
2010-12-28 |
1247 |
In the second sentence of Section 60.5, change:
to:
Reported by Justin Pryzby. |
2010-12-28 |
1260 |
About two thirds of the way down the page, change the paragraph:
to:
Explanation:
|
2010-12-31 |
1262 |
In the example code at the bottom of the page, change the two lines that read: setsockopt(sockfd, IPPROTO_TCP, TCP_CORK, sizeof(optval)); to:
Reported by Przemysław Pawełczyk. |
2010-11-28 |
1276 |
In the fourth line of Section 61.8, change:
to:
Explanation:
Reported by Justin Pryzby. |
2010-12-28 |
1327 |
Change the last sentence on the page:
to:
Explanation:
|
2011-01-06 |
1356 |
Below the prototype box for epoll_create(), change:
to:
Explanation:
|
2010-12-03 |
1358 |
Change the second-to-last line of Listing 63-4: if (epoll_ctl(epfd, EPOLL_CTL_ADD, fd, ev) == -1) to:
Reported by Sangman Lee. |
2011-03-07 |
1406 |
In the second paragraph of the small-font note two thirds of the way down the page (beginning "SUSv3 specifies..."), change:
to:
Reported by Subu Rama. |
2011-01-04 |
1503 |
In the entry for "uint32_t data type", remove the page reference "378". Explanation:
|
2010-10-25 |