Programming Perl

Errata for Programming Perl

Submit your own errata for this product.


The errata list is a list of errors and their corrections that were found after the product was released. If the error was corrected in a later version or reprint the date of the correction will be displayed in the column titled "Date Corrected".

The following errata were submitted by our customers and approved as valid errors by the author or editor.

Color Key: Serious Technical Mistake Minor Technical Mistake Language or formatting error Typo Question Note Update



Version Location Description Submitted By Date Submitted Date Corrected
Printed
Page xviii
last line: changed "ftp.ora.com" to "ftp.oreilly.com"

Anonymous    Sep 01, 1997
Printed
Page xxi
changed both instances of "ora.com" to "oreilly.com"

Anonymous    Sep 01, 1997
Printed
Page 29
In para 4, line 1, changed: spp to spp

line 2, changed: /home/spp to /home/spp:

Anonymous    Jul 01, 1999
Printed
Page 37
The second and third entries of the second table were changed to

@days[3,4,5] Same as ($days[3], $days[4], $days[5]) @days[3..5] Same as ($days[3], $days[4], $days[5])

Anonymous    Apr 01, 1999
Printed
Page 55

Line -2, above footnote: "older version of Perl" now reads: be "older versions of Perl"

Anonymous    Jul 01, 1999
Printed
Page 56

last paragraph reads: "It you're trying to do variable interpolation..." Should read: "If you're trying to do variable interpolation..."

Anonymous   
Printed
Page 60
In para 2, line 1, changed:

Now that you've seen some of the things you'll be seeing, to: Now that you've seen some regular expressions,

Anonymous    Jul 01, 1999
Printed
Page 69
Changed

/(?:(?!foo)...|^..?)bar/ to /(?:(?!foo)...|^.{0,2})bar/

Anonymous    Apr 01, 1999
Printed
Page 77
table row 1, column 2: "." changed to ".."

Anonymous    Aug 01, 1998
Printed
Page 77
In the table at the top of the page, row 1, column 2: ".." has been

changed to ".. ..."

Anonymous    Jul 01, 1999
Printed
Page 84
In para 4, line 2, changed "However. If the thing following" to

"However, if the thing following"

Anonymous    Jul 01, 1999
Printed
Page 89
line 5 changed to

if ( ("fred" & "1234") =~ /[^]/ ) { ... }

Anonymous    Aug 01, 1998
Printed
Page 94
"Logical and, or, not, and xor": Please move this section to be closer to

the "Bitwise Operators" section. (When I was searching for a logical equivalent to "^", I didn't even see this section, because the section after "Bitwise Operators" lists And and Or.)

Anonymous   
Printed
Page 97
In para -1, line -1, changed: "Your authors would tend to prefer"

to "Your readers would tend to prefer"

Anonymous    Jul 01, 1999
Printed
Page 112
In the paragraph following examples, changed

all return values are likewise returned to multiple return values are likewise returned

Anonymous    Apr 01, 1999
Printed
Page 119
In para 2, all lines have space between a function name and its opening

parenthesis. (See Page 547, below.)

Anonymous   
Printed
Page 130
In para 2, line -3

immediately after setting $|, you may simply print ""; (The "" was in a different font from the rest of the book.)

Anonymous    Jul 01, 1999
Printed
Page 131
Bullet 1, line 2: "the all" now reads "all the"

Anonymous    Jul 01, 1999
Printed
Page 144
list item 4, "Filehandles, files and directories": add

"select (output filehandle)" and "select (ready file descriptors)"

Anonymous    Aug 01, 1998
Printed
Page 145-242
Perl Functions in Alphabetical Order

It's hard to search for the function you want. Please either list the function in the Table of Contents, or change the heading to list the first or last function on the page. I suggest the same thing for: pages 76- 94, Operators, and pages 378-516, Library Modules.

Anonymous   
Printed
Page 148
In para. 6, line 1:

"Alternately" should be "Alternatively"

Anonymous   
Printed
Page 152
closedir : "See the examples under opendir." "opendir"

changed to "readdir".

Anonymous    Aug 01, 1998
Printed
Page 153
The line

$pwd = (getpwuid $<)[1]; was changed to: $pwd = (getpwuid($<))[1];

Anonymous    Mar 01, 1998
Printed
Page 156
After "faster to use the undef command" added "on the whole hash"

Anonymous    Apr 01, 1999
Printed
Page 158
Paragraph 3, line 1: removed the extraneous comma after EXPR.

Anonymous    Mar 01, 1998
Printed
Page 168
In para 3, line -1, changed "example (which assumes we've

already calculated $cost and $quantity:" to "example (which assumes we've already calculated $cost and $quantity):"

Anonymous    Jul 01, 1999
Printed
Page 182
deleted the extra close paren in the first line of the third

code block: foreach $key (sort { $hash{$b} <=> $hash{a} } keys %hash)) {

Anonymous    Mar 01, 1998
Printed
Page 182
Changed

To sort an array by value to: To sort a hash by value

Anonymous    Apr 01, 1999
Printed
Page 194
changed next-to-last code example from

$file =~ s#^s#./$&#; open FOO, "< $file"; to $file =~ s#^(s)#./$1#; open (FOO, "< $file");

Anonymous    Mar 01, 1998
Printed
Page 195
last line of text: changed "give" to "gives"

Anonymous    Mar 01, 1998
Printed
Page 200
Under printf, the lines

printf FILEHANDLE LIST printf LIST were changed to: printf FILEHANDLE FORMAT LIST printf FORMAT LIST

Anonymous    Mar 01, 1998
Printed
Page 223
Changed

printf "%${width}.${precision}f ", $value; to: $output_arr[$precision] = sprintf "%${width}.${precision}f", $value;

Anonymous    Apr 01, 1999
Printed
Page 230
code sample 2: line 9,

elsif ($rc > 0x80) changed to elsif (($rc & 0xff) == 0) { code sample 2,last line, $ok = ($rc != 0); changed to $ok = ($rc == 0);

Anonymous    Aug 01, 1998
Printed
Page 231

The next-to-last line of the code sample used to read: }; The semi-colon was removed. It now reads: }

Anonymous    Apr 01, 1999
Printed
Page 241
1st text para. under "waitpid", line 2: "or if the FLAGS"

Insert 0 between "or" and "if"

Anonymous    Aug 01, 1998
Printed
Page 246
In para 2, line -2, changed

$coderef = &handler; to $code_ref = &handler; (It looked like "deref", but it's a reference, not a dereference.)

Anonymous    Jul 01, 1999
Printed
Page 254
first example, last line

${"${pkg}::$name"} = 5; changed to ${"${$pkg}::$name"} = 5;

Anonymous    Aug 01, 1998
Printed
Page 263
In the bottom paragraph, "Suppose $LoL is already an array of

references to arrays." changed to "Suppose @LoL is already an array of references to arrays."

Anonymous    Mar 01, 1998
Printed
Page 263
In para 2, line 1, changed "and therefore yields the a count"

to "and therefore yields a count"

Anonymous    Jul 01, 1999
Printed
Page 289
para. 4, sentence 1 changed to

"An object is a data structure with a collection of behaviors." (Remove "that the data structure is capable of")

Anonymous    Aug 01, 1998
Printed
Page 292
Line 3: "should generally treated" changed to "should generally

be treated".

Anonymous    Mar 01, 1998
Printed
Page 299
last paragraph: "When the block is exited" changed to

"When a block is exited"

Anonymous    Aug 01, 1998
Printed
Page 302
last paragraph: added a right parenthesis to the end

of the paragraph.

Anonymous    Aug 01, 1998
Printed
Page 306
para. 2 line 2: put "BSD::Resource" in constant width font

Anonymous    Mar 01, 1998
Printed
Page 347
2nd text para.: "more that one" now reads "more than one"

Anonymous    Jul 01, 1999
Printed
Page 349
line 5 of code: added a space between "$remote," and

"$port"

Anonymous    Aug 01, 1998
Printed
Page 350
code example at top of the page, the line

print Client "Hello there, $name, it's now ", changed to print CLIENT "Hello there, $name, it's now ", (Just changed "Client" to "CLIENT")

Anonymous    Aug 01, 1998
Printed
Page 393
lines -4 through -2: The untie and the undef statements were

reversed, as shown: untie %db_hash; undef $db_obj; # removing the last reference to the DB # closes it. Closing DB_FH is implicit. now reads: undef $db_obj; # removing the last reference to the DB # closes it. Closing DB_FH is implicit. untie %db_hash

Anonymous    Aug 01, 1998
Printed
Page 414
The example line

perl Makefile.PL ... added an extra space and backslash at the end

Anonymous    Aug 01, 1998
Printed
Page 440
Changed

use File::Path To use File::Path;

Anonymous    Apr 01, 1999
Printed
Page 442
near end of code

$fh->setpos $pos; changed to: $fh->setpos($pos);

Anonymous    Aug 01, 1998
Printed
Page 444
third last line

tie %hash, ... changed to: tie (%hash, ...

Anonymous    Aug 01, 1998
Printed
Page 451
The line

$bar = 'blech' changed to: $opt_foo = 'blech'

Anonymous    Aug 01, 1998
Printed
Page 460
second code block, lines 1 and 4

$h = -20.00732 * 1.7; # 34.012444 .... ... $h = -20.00732 * $g; # "34.012444" ... (Removed the hyphens: the numbers changed to "20.00732")

Anonymous    Aug 01, 1998
Printed
Page 462
last example, last line

untie %h; changed to: untie %hash;

Anonymous    Aug 01, 1998
Printed
Page 475
Para assert, line 1, changed "Similar to C macro assert(3)."

to "Similar to the C macro assert(3).

Anonymous    Jul 01, 1999
Printed
Page 489
In paras -1-2, lines 2-3

Changed: names-pace to: name-space

Anonymous    Jul 01, 1999
Printed
Page 508
at the end of the list of "ok" and "not ok" lines, add another "not

ok" line

Anonymous    Aug 01, 1998
Printed
Page 531
In para 3, line 1

Changed : Curlies are required on if and while blocks. to: Braces are required on if and while blocks.

Anonymous    Jul 01, 1999
Printed
Page 540
bullet item -2: "unpack 'u' and pack '%' formats" should be

"pack 'u' and unpack '%' formats"

Anonymous    Dec 01, 1998
Printed
Page 547
In para 9, line 1

Changed: Do not put space between a function name and its opening parenthesis. to: Do not put space between a function name instance and its opening parenthesis.

Anonymous    Jul 01, 1999
Printed
Page 602
under "command bufferring" the see also changed to "buffer" not

"buffering"

Anonymous    Aug 01, 1998
Printed
Page 608
AV referred to in definition of HV changed to HV.

Anonymous    Mar 01, 1998
Printed
Page 622
index entry "$_($ARG)": "forearch" should read "foreach"

Anonymous    Aug 01, 1998
Printed
Page 623
index entry "- (hyphen), -. (arrow) operator" should also

refer to page 295

Anonymous    Aug 01, 1998
Printed
Page 623
index entry "# (sharp), for comments": "57" changed to "58"

Anonymous    Aug 01, 1998
Printed
Page 624
index entry "arrow (->) operator" should also

refer to page 295

Anonymous    Aug 01, 1998
Printed
Page 626
added page "183" to "capitalization, changing". Also added the

line "(see also capitalization)" under the entry for case sensitivity. (Actually, Seth did the index changes, not me.)

Anonymous    Sep 01, 1997
Printed
Page 627
added entry for "compiler for Perl, 369"

Anonymous    Mar 01, 1998
Printed
Page 627
index entry for "comments": "57" changed to "58"

wrong page

Anonymous    Aug 01, 1998
Printed
Page 627
entry for d has been changed from "27" to "28"

Anonymous    Dec 01, 1998
Printed
Page 630
added entry for "flush, 70, 442"

Anonymous    Mar 01, 1998
Printed
Page 630
index entry "filehandles": remove subentry "copying, 438"

Anonymous    Aug 01, 1998
Printed
Page 634
added the entry "lowercase, converting to, 183".

Anonymous    Sep 01, 1997
Printed
Page 634
index entry "local functions": add reference to page 184

Anonymous    Aug 01, 1998
Printed
Page 637
index entry "paragraph mode": add reference to page 132

Anonymous    Aug 01, 1998
Printed
Page 640
In the "-s switch" entry, the reference to pages 517-527 was

removed.

Anonymous    Mar 01, 1998
Printed
Page 640
entry for s has been changed from "27" to "28"

Anonymous    Dec 01, 1998
Printed
Page 643
the index should include the entry,

"tr/// (translation) operator, 74, 234"

Anonymous    Aug 01, 1998
Printed
Page 645
entry for w has been changed from "27" to "28"

Anonymous    Dec 01, 1998
Printed
Page 648
(colophon) added the following at the end of the next-to-last

para.: Whenever possible, our books use RepKover (tm), a durable and flexible lay-flat binding. If the page count exceeds RepKover's limit, perfect binding is used.

Anonymous    Sep 01, 1997