Commit 59359e4f authored by Paul E. McKenney's avatar Paul E. McKenney
Browse files

rcutorture: Handle non-statistic bang-string error messages



The current console parsing assumes that console lines containing "!!!"
are statistics lines from which it can parse the number of rcutorture
too-short grace-period failures.  This prints confusing output for
other problems, including memory exhaustion.  This commit therefore
differentiates between these cases and prints an appropriate error string.

Signed-off-by: default avatarPaul E. McKenney <paulmck@kernel.org>
parent 61251d68
Loading
Loading
Loading
Loading
+15 −3
Original line number Diff line number Diff line
@@ -44,11 +44,23 @@ then
		tail -1 |
		awk '
		{
			for (i=NF-8;i<=NF;i++)
			normalexit = 1;
			for (i=NF-8;i<=NF;i++) {
				if (i <= 0 || i !~ /^[0-9]*$/) {
					bangstring = $0;
					gsub(/^\[[^]]*] /, "", bangstring);
					print bangstring;
					normalexit = 0;
					exit 0;
				}
				sum+=$i;
			}
		END { print sum }'`
		print_bug $title FAILURE, $nerrs instances
		}
		END {
			if (normalexit)
				print sum " instances"
		}'`
		print_bug $title FAILURE, $nerrs
		exit
	fi