that's not what risk means. no investment considers early exit because of difficulty as a risk. even legislation call that "investor profile" or something meaningless or another.
By selling a bond before maturity, you're open to price fluctuations of the bond. It's not that the investor is exiting early, it's that by exiting early he is no long guaranteed the yield of the bond when he purchased it. Thurs, the yield is not "risk-free", and the risk is that the price moved in the market.