Commit Graph

13 Commits

Author SHA1 Message Date
Gerald Combs 4905983845 More shellcheck checks and fixes.
Remove a libtool check while we're here.

Change-Id: I813add2031480f34ce89f268b541f8939016c2c7
Reviewed-on: https://code.wireshark.org/review/28066
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2018-06-07 18:11:12 +00:00
Dario Lombardo 8a5385b9c9 More licenses converted to SPDX.
Change-Id: Id4f987dcdacf06622d70263f4659a4400e30dc39
Reviewed-on: https://code.wireshark.org/review/26332
Petri-Dish: Dario Lombardo <lomato@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-03-07 13:35:49 +00:00
Gerald Combs b725d6c9ac Add an initial "shellcheck" target.
Look for shellcheck in Autotools and CMake, and if found add a target
that checks some of our shell scripts.

Add a "source=" directive to targets that include test-common.sh so
that shellcheck will correctly process the scripts. Note that this
requires shellcheck 0.4.0 or later.

To do: Fix the issues that shellcheck found and check more scripts.

Change-Id: I441f9f59d8a3f8eec6718119c2370f2560b98f3c
Reviewed-on: https://code.wireshark.org/review/17943
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-09-26 23:17:02 +00:00
Gerald Combs 17546ad883 Check for ASAN when fuzzing.
Try to determine if we passed -fsanitize=address to gcc or clang and
adjust the ASAN variable fuzz-test.sh, randpkt-test.sh and
test-captures.sh accordingly.

Change-Id: I88a34828fb5875e1a74a3b180ffb3da37daac0bd
Reviewed-on: https://code.wireshark.org/review/17848
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2016-09-24 21:04:31 +00:00
Guy Harris 876bca186b Add a -a flag to use if TShark was built with ASan.
We mustn't set the virtual address space limit if that's the case, as
ASan consumes a ton of address space.

Clean up a comment while we're at it.

Change-Id: I7e88135f16b21cb091a73a35de70bee757fb3876
Reviewed-on: https://code.wireshark.org/review/17847
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-09-21 21:43:52 +00:00
Evan Huus 8f40e2cd8d tools: permit setting BIN_DIR in the environment
For out-of-tree builds you have to pass the location of your build to our tools
like the fuzz script, valgrind script etc. Modify them so that the value can be
set in the environment rather than requiring a shell script flag.

Set the environment variable in the vagrant provision step, so that the scripts
Just Work (TM) in the VM.

Change-Id: If8ce6b278176085ba6dd994137b82fc989b80124
Reviewed-on: https://code.wireshark.org/review/9168
Reviewed-by: Evan Huus <eapache@gmail.com>
2015-06-26 06:52:58 +00:00
Bill Meier 550e3153bf Fix fuzz-test.sh '-b' option so it works again; Do some other tools/*test*.sh changes
- Add -b option to randpkt-test.sh and test-captures.sh;
- Create/ue a common function to do '-x' tests on files/dirs;
- Rename exit_error function to ws_exit_error

Change-Id: I032c9d784bec1fb6b0717aaad08a061e4d935476
Reviewed-on: https://code.wireshark.org/review/872
Reviewed-by: Bill Meier <wmeier@newsguy.com>
Tested-by: Bill Meier <wmeier@newsguy.com>
2014-03-30 21:03:15 +00:00
Jeff Morriss 82e2865739 Remove $Id$ and other Subversion leftovers from the tools.
There are a few things in here which could still use attention.

Don't regenerate anything now.

Change-Id: I283c224d3523212144707fca3d6265916cb11792
Reviewed-on: https://code.wireshark.org/review/205
Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.com>
2014-02-14 01:35:57 +00:00
Jeff Morriss 470bd4455a Add a new environment variable to cause abort()s if we add too many items
to the tree (to separate this case from the generic DISSECTOR_BUG case).

Enable this environment variable when fuzz testing.

Enable the 3rd (without tree but with a read filter) check (added in r49643)
when testing capture files but not when fuzz testing--not sure if we want to
add even more to the fuzzbot's work load now (OTOH I've been running it for
a while and it hasn't buried me in bugs).

svn path=/trunk/; revision=49784
2013-06-05 14:08:40 +00:00
Jeff Morriss b49c3e7eca Oh yeah, -R is now -Y in trunk.
svn path=/trunk/; revision=49646
2013-05-31 02:03:03 +00:00
Jeff Morriss c56c403a52 As discussed in https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8728#c4 :
Running tshark with a read filter ("-R") and without building the full tree
("-V") causes it to run into some more bugs (usually loops adding more than
100000 items to the tree).  Add some (commented out for now) code to do
this...

svn path=/trunk/; revision=49643
2013-05-31 01:38:55 +00:00
Jeff Morriss 4509929f2a Exit if we can't load the test-common.sh library.
svn path=/trunk/; revision=49625
2013-05-30 00:35:46 +00:00
Evan Huus 7d63573632 Update test-fuzzed-cap.sh:
- support testing multiple files at once
- use tools/test-common.sh to make sure we have the most up-to-date environment
  variables set (the old version was missing the WMEM_ one for example)
- rename to test-captures.sh since it works just fine on non-fuzzed files

svn path=/trunk/; revision=49412
2013-05-19 12:51:35 +00:00