Errata in K&R C v2, page 97 (was: [PATCH v2] CONTRIBUTING: Please sign your emails with PGP)

Alejandro Colomar
2023-11-22T20:19:25Z

[-- Attachment #1: Type: text/plain, Size: 905 bytes --]

Hello Brian,

> On Wed, Nov 22, 2023 at 10:25:57AM -0600, G. Branden Robinson wrote:
> > [1] I encourage anyone with either a reverential or heretical turn of
> > mind to review §5.5 of the 2nd edition of _The C Programming
> > Language_ and consider it light of our string_copying(7)
> > discussions. I would attend particularly to what is implied by the
> > recommendation of Exercise 5-5 to implement strncat(3), strncmp(3),
> > and strncpy(3) from scratch.

I just found an erratum in K&R C v2 §5.5: In page 97, in the picture,
'amessage' and 'pmessage' are switched (IMO); pmessage should be the one
with the two boxes and an arrow, since it's the pointer one. We didn't
find it in the existing list of errata[1], which Branden pointed to me.

[1]: <https://www.cs.princeton.edu/~bwk/cbook.html>

Cheers,
Alex