]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
imagedetailspage: Fix crash with more than 15 layers
authorRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 2 Dec 2013 17:41:58 +0000 (17:41 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 2 Dec 2013 17:43:14 +0000 (17:43 +0000)
If you had more than 15 layers the system would crash since one more
value is added to one array than the other. This fixes the code
so equal numbers of values are added to the arrays and hence
doesn't crash when many layers are enabled.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
lib/bb/ui/crumbs/imagedetailspage.py

index 4c862474e9dc0a938319a489364e6445ff26cbf5..271635fe1184407893fc0e94dfebec9a1749b321 100755 (executable)
@@ -355,9 +355,9 @@ class ImageDetailsPage (HobPage):
             vallist.append(base_image)
             i = 0
             for layer in layers:
-                varlist.append(" - ")
                 if i > layer_num_limit:
                     break
+                varlist.append(" - ")
                 i += 1
             vallist.append("")
             i = 0