A continuous time risk model is considered, where the premium rate is constant and the claims form a compound Poisson process. We assume that an injection is made, which is an immediate increase of the surplus up to level u > 0 (initial level), when the level of the surplus goes below (0 < < u). We derive the formula of the ruin probability of the surplus by establishing an integro-differential equation and show that an explicit formula for the ruin probability can be obtained when the amounts of claims independently follow an exponential distribution.