On 06/27/12 13:11, Brock Pytlik wrote:
On 06/26/12 14:43, Shawn Walker wrote:
On 06/25/12 17:25, Brock Pytlik wrote:
Webrev:
https://cr.opensolaris.org/action/browse/pkg/bpytlik/7177231-v1
Bug:
7177231 displayed license is always for installed copy if license file
is present
src/modules/actions/license.py:
line 193: Don't need open() here since fh is never used.
get_data_digest() can accept either a path or fh, so i'd just pass it
the path as you are now and drop the open() call. You should leave the
exception handler in place though.
Thanks for catching that. I agree that opening it twice is silly, but
I'm not thrilled with separating the open from the place where we catch
the exception from the open for no real reason. So, I think I'll pass in
the file handle and the length to get_data_digest, which should work
just as well.
That works too, although I don't see any real difference between the
approaches.
-Shawn
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss