Racing cars is a very competitive sport, usually in hot weather and without air conditioning (which would add weight and use power) so the drivers body sweats alot, several pints over a long race, this dehydrates the body and decreases the need to pee, but if a driver really must go then he has two options, stop and pay a visit or drive cross legged.
Chat with our AI personalities
It would be physically impossible when on the track with the G forces and the pit stop is about 4 seconds so not going to work their either so imagine the answer is they can't!!