Maybe, maybe not... stylists shears and thinning razors for those expensive haircuts could be dangerous also.
My bet is that if there is a barber involved he gets checked out thoroughly, much like the staff at the White House, etc.
Mr. Obama and McCain get a degree of protection, but neither man is actually the President yet. No doubt whatever occurs it is checked out, within reason, but realistically the candidates travel by plane and other vehicles, which can have accidents; they eat food cooked for them by others, which is a risk of course also. I don't think there's any reason to think they couldn't be professionally groomed, should they wish. I almost lean to the idea that they DO. Just not sure they themselves would use a straight or not.
John P.