]> git.ipfire.org Git - thirdparty/rrdtool-1.x.git/commitdiff
Fixed tests when VERBOSE is on 703/head
authorJean-Michel Vourgère <nirgal@debian.org>
Thu, 24 Mar 2016 05:18:01 +0000 (06:18 +0100)
committerJean-Michel Vourgère <nirgal@debian.org>
Thu, 24 Mar 2016 05:18:01 +0000 (06:18 +0100)
Define RRDTOOL_V from RRDTOOL, but only after RRDTOOL is defined.
Output the header showing witch command is run on stderr, not stdout.

tests/functions

index 4ddc96bd639acbfe0bb500b097a6e72d97bda446..f12af726c3849dd457f12f572e64759af0149169 100644 (file)
@@ -68,7 +68,7 @@ function valgrind {
 }
 
 function verbose_rrdtool {
-       echo "$RRDTOOL_V" "$@"
+       echo "$RRDTOOL_V" "$@" >&2
        "$RRDTOOL_V" "$@"
 }
 
@@ -142,11 +142,6 @@ function exit_if_cached_running {
         fi
 }
 
-if [ -n "$VERBOSE" ] ; then
-       RRDTOOL_V="$RRDTOOL"
-       RRDTOOL=verbose_rrdtool
-fi
-
 if [ -z "$RRDTOOL" ] ; then 
         RRDTOOL=$TOP_BUILDDIR/src/rrdtool
         RRDCACHED=$TOP_BUILDDIR/src/rrdcached
@@ -178,3 +173,8 @@ if [ -z "$RRDTOOL" ] ; then
                 run_cached "$STANDARD_RRDCACHED"
         fi
 fi
+
+if [ -n "$VERBOSE" ] ; then
+       RRDTOOL_V="$RRDTOOL"
+       RRDTOOL=verbose_rrdtool
+fi