| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
| |
The function does the same as `mask2plen' but for IPv6.
Signed-off-by: Florian Forster <octo@leeloo.lan.home.verplant.org>
|
|
|
|
| |
whether XXX->YYY is null.
|
|
|
|
|
|
|
|
|
| |
- seperate fields by comma
- use [] for flags and options sets
- print a trailing length field
make use of tok2str() and bitttok2str()
move port definitions into tcp.h
|
| |
|
|
|
|
| |
ID for loopback OAM cells rather than attempting to print it
|
|
|
|
| |
safeputchar
|
| |
|
| |
|
|
|
|
|
|
| |
(in micro-second resolution) between the first and current packet.
- cleanup the the ts_print code a bit -> add a ts_format helper
|
|
|
|
|
|
|
|
| |
midnight GMT; just use time().
We also don't need to flush the standard error right before exiting.
Clean up white space.
|
|
|
|
| |
gettimeofday() for win32 platforms
|
|
|
|
| |
per the problems found by Gerald Combs.
|
|
|
|
|
| |
Make "fn_printzp()" return 0 if we don't run past the end of the packet
and we don't find any padding NULs.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
with a maximum length, where a string shorter than that length is padded
with NULs), as "fn_print()" won't handle the maximum length *and* the
snapshot length and "fn_printn()" won't stop on a null string. Use it
where appropriate.
Always pass "snapend" to "fn_print()" and "fn_printn()" if they're
passed a pointer into the packet data; only pass NULL if they're being
handed a pointer into a buffer that's not part of the packet data.
Always check the return value of "fn_print()", "fn_printn()", and
"fn_printzp()" if they're passed "snapend", and do the appropriate
string termination and "packet truncated" indication if they return 1.
|
| |
|
|
|
|
| |
"tok2strbuf()".
|
|
|
|
|
|
|
|
| |
printer
-harden tok2str() and bittok2str() to catch NULL refs
-don't attempt to print a frame-relay IE if there is not enough bytes on the wire
to print at least a full TLV
|
|
|
|
|
|
|
|
| |
tflag values correspond to what output formats (e.g., 4 means "-tttt").
Switch on the tflag value to determine whether to call "gmt2local()" to
set "thiszone", just as we switch on it to determine the format for time
stamps, to make it more obvious in what cases we call it.
|
| |
|
|
|
|
| |
a buffer, and make tok2str a wrapper for this.
|
|
|
|
| |
that it can be called up to 4 times in a given "printf()".
|
|
|
|
| |
replacement
|
|
|
|
|
|
|
|
|
|
| |
appropriately, and that GNUmakefile and the MSVC++ project file define
it apppriately, as we do with libpcap, rather than defining it in
"interface.h".
Undo the rcsid-shuffling and addition of extra #includes, as we no
longer need to arrange that "interface.h" be included before using _U_
in an RCS ID or copyright.
|
|
|
|
|
|
|
|
|
|
|
| |
use "_U_" in the definitions of "rcsid[]", to eliminate
complaints about those variables being unused;
move the definitions after the include of "interface.h", or add
an include of "interface.h", so that "_U_" is defined.
Include "config.h" before including "tcpdump-stdinc.h" in
"missing/datalinks.c".
|
| |
|
|
|
|
|
|
|
| |
for prefixes at bitmasks[32] (the last element of a 33-element array),
not bitmasks[33] (one past the last element of that array).
Clean up white space.
|
|
|
|
|
| |
indication if the last byte of the counted string was the last
byte captured.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
open the file containing a filter expression in binary mode, so
that we get all the characters that "fstat()" claims are there,
rather than having CRs stripped out (causing us to report an
error because the "read()" call gives us less data than
"fstat()" claims was in the file);
close the file descriptor once we're finished reading the file;
strip out everything on a line starting with "#", so that "#"
can be used for to-end-of-line comments in the file.
Update his address in the CREDITS file.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
this is useful for scanning bitfields
the input is a tokenlist and a testvalue
the function will parse the tokenlist for each single bitmatch
of the testvalue;
if it finds a a match it will write teh tokenstring into a buffer
and place a comma to seperate the values
if there is no match it will format the buffer according to the format string;
i saw many private instances of similar bitscanning functions;
lets use bittok2str() from now on;
|
| |
|
|
|
|
|
| |
are included by <tcpdump-stdinc.h>, so we don't have to include them
explicitly; <errno.h> isn't needed by print routines).
|
|
|
|
| |
compilers.
|
| |
|
|
|
|
| |
print_unknown_data{} supports identation;
|
| |
|
|
|
|
|
|
|
| |
from the argument, rather than the argument itself, when testing whether
it should be printed or not (the argument might well be a sign-extended
version of an 8-bit character, in which case it's < 0x80 as it's
negative, but it can't be safely handed to "isprint()").
|
| |
|
|
|
|
| |
array of strings instead of a list of value/string pairs.
|
| |
|
|
|
|
| |
Check for malloc failure in read_infile()
|
| |
|
| |
|
| |
|
|
|
|
| |
<gvanem@eunet.no>
|
|
|
|
|
| |
move safeputchar() and safeputs() into util.c for better code sharing.
some style.
|
|
|
|
| |
From Francisco Matias Cuenca-Acuna <mcuenca@george.rutgers.edu>
|
|
|
|
|
| |
there seem to be couple of unsafe use of strcat and strcpy - we should
bring in strl{cat,cpy}.
|