On 01/22/2014 07:46 AM, Dylan Baker wrote: > Normally piglit doesn't generate test names with leading slashes, and > the code has no way to deal with them. In fact, a leading slash will > cause a loop in Summary.__init__ to run infinitely. The simplest > solution is an assertion, which means the program will assert before it > ever gets to the loop. > > Signed-off-by: Dylan Baker <[email protected]> > --- > framework/summary.py | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/framework/summary.py b/framework/summary.py > index 6ee1226..2ba5f16 100644 > --- a/framework/summary.py > +++ b/framework/summary.py > @@ -281,6 +281,12 @@ class Summary: > status = self.status[results.name] > > for key, value in results.tests.iteritems(): > + # if the first character of key is a / then our while loop > will > + # become an infinite loop. Beyond that / should never be the > + # leading character, if it is then there is a bug in one of > the > + # test profiles. > + assert key[0] != '/' > + > #FIXME: Add subtest support > > # Walk the test name as if it was a path, at each level > update >
Both of these are: Reviewed-by: Kenneth Graunke <[email protected]>
signature.asc
Description: OpenPGP digital signature
_______________________________________________ Piglit mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/piglit
