/usr/bin/*-survey when ran,
- calls cleanup() twice, resulting in non-zero exit status,
- and attempts to cleanup already cleaned/detached echo client,
resulting in invalid argument.
This patch fixes the same.
Test-Parameters: trivial testlist=obdfilter-survey
Signed-off-by: Parinay Kondekar <Parinay.Kondekar@seagate.com>
Change-Id: I5bb1fe5d7e6adf15e81d88501d6edbda1c5ef3c3
Reviewed-on: https://review.whamcloud.com/27160
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
# do cleanup and exit.
cleanup () {
+ trap 0
+
local exit_status=$1
local host