It is possible that the cactus became somewhat susceptible to a fungal or bacterial infection during the repotting. Did you water it after the repotting? If so and you had damaged roots there is a chance your cactus caught something. If it is relatively cool and humid where you live it is not that hard for the cactus to pick up something when it has been shocked like repotting can do to it.
I guess I can see two ways to approach this:
1. the less drastic one: find yourself some systemic fungicide and/or antibacterial products that you can use on the cactus - you can spray it in the location where this is occurring (probably want to do that outside) and add it to the water you give the cactus. If it is a minor affliction that should make this stop - unfortunately the disfigurement on the cactus will not go away.
2. the drastic one: cut the cactus below where this is happening inspect the flesh and see if it looks healthy - if it is healthy the root system is likely OK and the cut will dry out and with time the cactus will likely develop a new growth point at the spot of the cut or develop a branch (or two) on the stem below that.
If the flesh looks sick - dark brown to black discoloration - there is a good chance the roots are in bad shape. Then you need to bareroot it, so thoroughly remove all the soil and inspect the roots, if there is any rot going on you will want to cut that away and then leave the remainder of the plant in a warm dry place for a week or so to thoroughly dry out, before potting up in fresh well draining soil, then refrain from watering for a good while and keep your fingers crossed that the cactus recovers.
If the roots are affected you can take the top you cut off and if there is enough stem above where this is happening you can then cut the affect area away inspect for healthy green flesh, let that dry out thoroughly for a week and stick the top piece in fresh well draining soil and do not water till you see evidence of new growth. As long as you have enough healthy stem above the affected area and are very careful not to water too soon, you should be able to get that top part to root, for most cacti that is the easiest way to propagate it, so could be one way to at least safe part of the plant in case whatever is affecting it is quite bad.
I guess I would suggest starting with option one, but I have seen something similar looking on a plant of mine and also decided to take the first approach, but whatever it was that was affecting the plant spread super fast despite my treatment and by the time I decided to go with option 2, it was too late and despite my best efforts I could not safe the cactus, which in my case I had been growing for about 7 years.