Remove a paragraph left over from the process of editing.
Indicate what the individual ND_TCHECK_*() macros do, and indicate that
*n*, in the GET_*_n() macros, is the length of the item to be fetched,
in bytes.
Expand the discussion of why bounds checks are a Good Thing.
List all the macros, including the "fetch an address and return a string
representation of the address" macros, and indicate what they do. Note
the additional advantage that they provide, namely that they 1) can
fetch unaligned values correctly and without a fault and 2) will fetch a
value in the specified byte order and return it in host byte order.
If the environment variable INSTRUMENT is
- unset or set to an empty string, print nothing, like with no
instrumentation
- set to "all" or "a", print all the functions names
- set to "global" or "g", print only the global functions names
The configuration with --enable-instrument-functions remains.
Note that before this change, the default was to print all functions.
Now it is to print nothing. So by default 'make check' runs without errors.
This allows to run:
$ INSTRUMENT=a ./tcpdump ...
$ INSTRUMENT=g ./tcpdump ...
$ INSTRUMENT= ./tcpdump ...
or
$ export INSTRUMENT=global
$ ./tcpdump ...
This also allows to run the statically compiled binary on another host
after copying it.
It is no longer necessary to modify the configuration with:
$ make instrument_all
$ make instrument_global
$ make instrument_off
(Targets removed.)
Update .gitignore, CONTRIBUTING.md and Makefile.in accordingly.
Moreover:
Reduce the scope of a variable.
Rename a variable.
Remove '\n' in the perror() call.
Remove 2 spaces in function calls (style).
[skip ci]