Code review updates

These are updates based on your code review so far.  I put them in a branch off of channelwad.
I made these changes because testing with race detection revealed a problem.  Specifically, I can't call t.cmd.Wait() until I'm done reading from stdout and stderr, hence the new iowg WaitGroup.