[cairo-commit] 2 commits - perf/cairo-perf-diff-files.c test/cairo-test.c test/cairo-test.h

Chris Wilson ickle at kemper.freedesktop.org
Wed Oct 24 11:33:49 PDT 2007


 perf/cairo-perf-diff-files.c |    9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

New commits:
commit 483ebe866df539460861a05f5d5e8e56ab2f5430
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date:   Wed Oct 24 19:32:00 2007 +0100

    [cairo-test] Remove executable flag from source files.
    
    chmod a-x test/cairo-test.[ch]

diff --git a/test/cairo-test.c b/test/cairo-test.c
old mode 100755
new mode 100644
diff --git a/test/cairo-test.h b/test/cairo-test.h
old mode 100755
new mode 100644
commit 1651359ffbda4c14eaf4e79b6deced4f2c247686
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date:   Wed Oct 24 18:35:41 2007 +0100

    [cairo-perf-diff-files] Only use a valid initializer for min_test.
    
    Do not assume that the tests[0] is a valid test, but instead scan for
    the first test that has a name (i.e. is not a terminator).

diff --git a/perf/cairo-perf-diff-files.c b/perf/cairo-perf-diff-files.c
index 05e3fa3..5fdf72d 100644
--- a/perf/cairo-perf-diff-files.c
+++ b/perf/cairo-perf-diff-files.c
@@ -644,8 +644,13 @@ cairo_perf_reports_compare (cairo_perf_report_t		*reports,
 
 	/* Find the minimum of all current tests, (we have to do this
 	 * in case some reports don't have a particular test). */
-	min_test = tests[0];
-	for (i = 1; i < num_reports; i++) {
+	for (i = 0; i < num_reports; i++) {
+	    if (tests[i]->name) {
+		min_test = tests[i];
+		break;
+	    }
+	}
+	for (++i; i < num_reports; i++) {
 	    if (tests[i]->name &&
 		test_report_cmp_backend_then_name (tests[i], min_test) < 0)
 	    {


More information about the cairo-commit mailing list