[LTP] [PATCH] pan/ltp-pan.c: fix incorrect number of total tests

Cyril Hrubis chrubis@suse.cz
Mon Apr 10 15:50:21 CEST 2017


Hi!
>  pan/ltp-pan.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/pan/ltp-pan.c b/pan/ltp-pan.c
> index 1614c70..beed623 100644
> --- a/pan/ltp-pan.c
> +++ b/pan/ltp-pan.c
> @@ -645,7 +645,7 @@ int main(int argc, char **argv)
>  				strerror(errno));
>  		fprintf(logfile,
>  			"\n-----------------------------------------------\n");
> -		fprintf(logfile, "Total Tests: %d\n", coll->cnt);
> +		fprintf(logfile, "Total Tests: %d\n", (coll->cnt - starts));

This change does not make much sense to me. The coll->cnt is number of
tests loaded from the runtest file, right? The starts is basically
number of tests to be executed. The runltp script executes ltp-pan with
-S which means that starts is set to coll->cnt in the main() function
and so after this change it would print "Total Tests: 0" regardless.

-- 
Cyril Hrubis
chrubis@suse.cz


More information about the ltp mailing list