If there is a nut on that stud (And I think there is) between the wire and the solenoid body and if you are really good at it there is a stud repair kit that NAPA and other auto parts sells.
You remove the nut, thread this thing (Which by the way is brass) on in it's place, then attach the wire to it and you are good to go.
Just thought you'd like to know.
See what I am talking about here:
Starter/Solenoid Repair Stud
Also depending on the starter it should be possible to replace the stud, Or you could take the starter assembly to a starter rebuild shop. Would sure beat the price of a new one. and they will use a non-rusting stud.