Blood can leave only through a system of veins around the outside wall of the corpus cavernosum. The expanding tissue constricts these veins. This preventing blood from leaving. The penis becomes rigid as a result. 