[...] > diff --git a/ChangeLog b/ChangeLog > index daf9708..05b7e56 100644 > --- a/ChangeLog > +++ b/ChangeLog > @@ -1,5 +1,12 @@ > 2010-11-22 Mats Erik Andersson <[email protected]> > =20 > + Partially revert changes introduced in fd64a202. > > Alas, the has says nothing for the person reading the ChangeLog.
Good point. This is for the commit. A slip! > > --- a/ChangeLog > +++ b/ChangeLog > @@ -1,5 +1,15 @@ > 2010-11-22 Mats Erik Andersson <[email protected]> > =20 > + * src/traceroute.c: Include "xalloc.h". > + * src/traceroute.c (host): Deleted variable. > + (hostname, addrstr): New variables; > + (parse_opt) [ARGP_KEY_ARG]: Abolish gethostbyname. Only use > + xstrdup to copy argument. > > Nitpicker hat on... Double spaces after end-of-sentence period. > > diff --git a/src/traceroute.c b/src/traceroute.c > index 432e6e1..9caeb00 100644 > --- a/src/traceroute.c > +++ b/src/traceroute.c > @@ -158,9 +160,7 @@ parse_opt (int key, char *arg, struct argp_state > *state) > =20 > case ARGP_KEY_ARG: > host_is_given =3D true; > - host =3D gethostbyname (arg); > - if (host =3D=3D NULL) > - error (EXIT_FAILURE, 0, "unknown host"); > + hostname =3D xstrdup(arg); > > It would be useful to say what the unknown was here, i.e. use ARG in > the error message; same in the rest of the code. Space after opening > parenthesis. I do not understand the comment on "unknown". (Space _before_ parenthesis.) Regards, Mats
