Whamcloud - gitweb
LU-11591 llog: add synchronization for the last record
[fs/lustre-release.git] / lustre-iokit / obdfilter-survey / iokit-libecho
index 3cd02f6..a155d4b 100644 (file)
@@ -25,7 +25,7 @@
 # Copyright  2008 Sun Microsystems, Inc. All rights reserved
 # Use is subject to license terms.
 #
-# Copyright (c) 2012, 2014, Intel Corporation.
+# Copyright (c) 2012, 2017, Intel Corporation.
 #
 # This file is part of Lustre, http://www.lustre.org/
 # Lustre is a trademark of Sun Microsystems, Inc.
@@ -213,6 +213,8 @@ cleanup_network () {
 
 # do cleanup and exit.
 cleanup () {
+       trap 0
+
        local exit_status=$1
        local host
 
@@ -255,7 +257,7 @@ cleanup () {
        fi
        exit $exit_status
 }
-trap 'cleanup 0 $clean_srv_OSS $cleanup_oscs' SIGHUP SIGINT SIGTERM
+trap 'cleanup 0 $clean_srv_OSS $cleanup_oscs' EXIT SIGHUP SIGINT SIGTERM
 
 # gets echoclient device number and attach it to the client UUID
 # Results are  returned by an echo followed by an exit