Skip to content

Commit d10904b

Browse files
committed
Added more verbosity levels to match the ones in the dissector.
1 parent 8261717 commit d10904b

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

examples/cap2sop.sh

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,13 @@ Extract SOP message information from CAP_FILEs.
88
99
Options:
1010
-h display this help text and exit
11-
-v increase verbosity (stderr). A single -v will show critical, error, info
12-
and debug messages. Double -v will show trace messages as well. Note
13-
that double -v is VERY verbose. Use for troubleshooting a dissector.
11+
-v increase verbosity (stderr). A single -v will show critical messages.
12+
Add more v to increase the trace level up to 5 for DEBUG. Note
13+
that DEBUG is VERY verbose. Use only to troubleshoot a dissector.
1414
1515
Example:
1616
${0##*/} -v sop.pcapng
17+
${0##*/} -vvvvv sop.pcapng
1718
EOF
1819
exit 1 >&2
1920
}
@@ -43,13 +44,10 @@ done
4344

4445
# By default redirect tshark's STDERR to /dev/null.
4546
TSHARK_STDERR='2>/dev/null'
46-
SOP_TRACE=
47+
SOP_TRACE="-o sop.trace_level:$verbosity_level"
4748
if [[ $verbosity_level -ge 1 ]]; then
4849
TSHARK_STDERR=
4950
fi
50-
if [[ $verbosity_level -ge 2 ]]; then
51-
SOP_TRACE="-o sop.trace:TRUE"
52-
fi
5351

5452
shift $(( $OPTIND - 1 ))
5553

0 commit comments

Comments
 (0)