On 10/13/10 09:03 PM, Bart Smaalders wrote:
On 10/13/10 09:36, Keith Mitchell wrote:
Hi Jan,

It'd be better to check status and len() of the output before splitting
the output - if the command errors out and returns an empty string for
status, the "co[0].split()[1]" command will fail.

<just happened to be driving by...>

Alternatively, assume that things will work, but catch the resulting
exception instead.

This is a good suggestion, I have modified the code and updated
the webrev accordingly:
http://cr.opensolaris.org/~dambi/bug-6991546/


Also, if you put the status check & perror calls in an function,
you can trim many lines of repeated code.

In this case, I followed the spirit of the code. There are more
places in ict.py which would deserve the same, so changing that just at
one place does not seem right to me.
And for obvious reasons, at this point I would like to minimize the number
of changes in order to minimize risk of breakage.
Please let me know if that might sound reasonable.

Thank you for review !
Jan

_______________________________________________
caiman-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/caiman-discuss

Reply via email to