[oe] [PATCH] Add error handling to read_cache in stage-manager

Chris Larson clarson at kergoth.com
Tue Apr 27 14:10:20 UTC 2010


2010/4/27 Mickaël Chazaux <mchazaux at adeneo-embedded.com>

> Sometimes stage-manager crashes with this message :
> Traceback (most recent call last):
>  File
> "/home/mchazaux/projet/OE/openembedded/recipes/stage-manager/files/stage-manager",
> line 79, in <module>
>   cache = read_cache(options.cachefile)
>  File
> "/home/mchazaux/projet/OE/openembedded/recipes/stage-manager/files/stage-manager",
> line 34, in read_cache
>   cache[data[0]]['ts'] = int(data[1])
> IndexError: list index out of range
>
> This is due to a corrupted cache file. This patch adds an error message
> and continues parsing ignoring the wrong line. The file is then properly
> regenerated.
>
>
You forgot a Signed-off-by, best off doing a commit -s in the future.  Looks
okay to me.

Acked-By: Chris Larson <chris_larson at mentor.com>
-- 
Christopher Larson
clarson at kergoth dot com
Founder - BitBake, OpenEmbedded, OpenZaurus
Maintainer - Tslib
Senior Software Engineer, Mentor Graphics



More information about the Openembedded-devel mailing list