In this paper we consider an extension of the two-dimensional risk model introduced in Avram, Palmowski and Pistorius (2008a). To this end, we assume that there are two insurers. The first insurer is subject to claims arising from two independent compound Poisson processes. The second insurer, which can be viewed as a different line of business of the same insurer or as a reinsurer, covers a proportion of the claims arising from one of these two compound Poisson processes. We derive the Laplace transform of the time until ruin of at least one insurer when the claim sizes follow a general distribution. The surplus level of the first insurer when the second insurer is ruined first is discussed at the end in connection with some open problems.