mirror of
https://github.com/the-tcpdump-group/tcpdump.git
synced 2024-11-27 12:03:44 +08:00
9939a0ff90
This change adds: year-month-day to the hours:minutes:secondes.{microseconds|nanoseconds}. It allows to catch more issues with timestamps processing. For some test using their own display time options, use 'SPECIAL_t' in options.
23 lines
728 B
Bash
Executable File
23 lines
728 B
Bash
Executable File
#!/bin/sh
|
|
|
|
# Update the tests given as positional parameters
|
|
|
|
TZ=GMT0; export TZ
|
|
|
|
for TEST in "$@"; do
|
|
PREFIX=tests
|
|
MATCH=0
|
|
while read -r name input output options
|
|
do
|
|
[ -z "$name" ] && continue # ignore empty lines
|
|
[ "${name#\#}" != "$name" ] && continue # ignore comment lines
|
|
[ "$name" != "$TEST" ] && continue # not the requested test
|
|
[ -z "$output" ] && continue # ignore incomplete lines
|
|
MATCH=1
|
|
# Word splitting is intentional for $options.
|
|
# shellcheck disable=SC2086
|
|
./tcpdump -# -n -tttt -r "$PREFIX/$input" $options >"$PREFIX/$output"
|
|
done < $PREFIX/TESTLIST
|
|
[ $MATCH = 0 ] && echo "test $TEST not found" >&2
|
|
done
|