On Thu, Sep 8, 2016 at 9:58 AM, Ross Burton <[email protected]> wrote:

> +    fn = tempfile.NamedTemporaryFile(mode="w+t")
> +    fn.write(script)
> +    fn.flush()
> +
> +    try:
> +        subprocess.check_output(("checkbashisms.pl", fn.name),
> universal_newlines=True, stderr=subprocess.STDOUT)
> +        # No bashisms, so just return
> +        return
>

Afaik, you should be using ‘with’ to ensure the temporary files are cleaned
up after use.
-- 
Christopher Larson
clarson at kergoth dot com
Founder - BitBake, OpenEmbedded, OpenZaurus
Maintainer - Tslib
Senior Software Engineer, Mentor Graphics
-- 
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

Reply via email to