Code review comment for lp://qastaging/~xnox/apparmor/py3

Revision history for this message
Evan (ev) wrote :

> - print open(i).read()
> + sys.stdout.write(open(i).read()+"\n")

This will leak fds, which python wonderfully loudly complains about in Python 3. It's also a good opportunity to replace any pairs of open() and close() with a with statement. If an open() and close() isn't wrapped in a with or try/finally, I would argue that is a bug.

« Back to merge proposal