Show error code when a child exits

This is useful for debugging problems with children.