The production rate of C+ from the photoionization of CO and CO2