It's not unusual for stainless steel to rust however it would generally be caused by the introduction of a contaminate in some form or other rather than the stainless steel product i
Put very simply stainless steel contains chromium which forms a passive outer layer (of chromium oxide) so long as there is oxygen, this is it's protective layer. Take the oxygen away in an area by an aggressive contaminate i.e. salty water droplets, spec of paint, iron oxide contamination, pollution, chemicals etc. and the oxygen is removed from that isolated spot and so starts corrosion.
Rarely the fault of the stainless steel itself (assuming it is top quality) but generally the fault of the keeper/owner of the product who does not understand the importance of keeping stainless steel clean and free of contamination.
I hear you say, so why have stainless steel, the answer is it's still far more resistant to 'rusting' than other steel.
Regarding the post about the Tikka rifles, somewhere along the line a contaminate was probably introduced. Now whether that was at the factory, proof house or retailer who knows but probably not the fault of an inferior stainless steel rifle barrel and action.
Remedy is to completely remove the rust spot or pitting by polishing out or an appropriate form of blasting. Then as far as guns go, keep clean or Cerekote it!
Having said all that, after many years in the marine industry, I've seen stainless steel with great chunks eaten out of it! This had more to do with highly inferior stainless steel and galvanic corrosion, something we should never see in guns.