Consider roller bearings and gear teeth.
A perfect ball in a perfect bearing is a geometric point contact. In a perfect roller in a perfect bearing, the contact is line contact, infinitely thin. In a gear, the two surfaces would similarly be called a line contact, again, of infinitely thin dimension.
In all those cases, the load is applied over an infinitely small surface area, so the surface stresses become infinite...but in a real universe, that does not happen.
The surfaces deform under "Hertzian" stresses, until the surface area is large enough for the load to be supported...
If those loads are too high, plastic deformation takes place.
If the stresses are in the elastic range, no permanent deformation takes place, and the material springs back to original form...some alloys have a fatigue limit, which if the cyclic stresses are low enough, the part can last literally forever, while other metals (e.g. Al, will eventually fail given enough cycles).
Now you can't fail a simple model in a cyclic compressive loads, as there's no tensile element to propogate cracks.
von Mises and Mohr worked out years ago that there was no such thing as simply applied stresses...a compressive stress on these points of contact, as materials have to deform to allow them creates tensile and shear stresses at angles related to them...see the wiki for Mohr's circle, which shows that for individually applied stresses, the stresses in other planes can be bigger than you would either calculate or guess without understanding.
So while the surface may be in true compression, there are other stresses at an angle to the applied stress which can be markedly higher, and contribute to fatigue cracking...
Other interesting thing about properly designed spur gear is that the surfaces are rolling, not sliding, they roll against each other (wrap a string around a rod, and the curve generated as you unroll it is the perfect tooth profile for rolling - do the same on an infinitely long flat surface, and you get a straight tooth...a rack...cutting a straight tooth rack will give the perfect tooth profile to a gear, and they will mesh perfectly).
As Molakule explained, there are a few fixes...other ones can involve cleaver gear design such that two or more teeth share the load at any one time, and I've used solid containing lubricants to distribute the loads better.
Oils also have a "pressure viscosity co-efficient", which under certain EHD conditions causes them to increase in viscosity markedly, and help spread the load. Off the top of my head I think PAO was pretty good there.
On some of our REALLY big gears (15 feet diameter), the lubricants are more akin to bitumen, not readily able to be squeezed out, and capable of momentarily spreading the load...those things last