Soft-gluon effects in WW production at hadron colliders