Probably depends on the situation. We had new windows delivered and the delivery guy held Connor while I wrote the check for the rest of the balance. He was right next to me and in my house so it didn't feel weird. He even said he has 3 kids at home but really misses the baby stage and was glad to do it.
But, no way a stranger out in public. People love babies so the woman was probably just trying to be nice. But, I think if you feel weird about it then you shouldn't do it. Your instincts are there for a reason