Quality of products plays a key role in attracting end-customers and helping firms gain a competitive advantage, but it is often beyond firms' control when the functional areas such as design, production, and assembly of their products are outsourced to independent contract manufacturers. To gain an improvement of the quality of products, firms have incentives to invest in their contract manufacturers. However, a contract manufacturer may jointly work with multiple competitive firms, which will potentially lead the investment of a firm to benefit its rivals and thus damage the competitive advantage of the investor. In this paper, we investigate the issue whether competitive firms should make quality investment to a common contract manufacturer under spillovers and demand uncertainty. We do so through considering a supply chain consists of two competitive buyers who focus on pricing and retailing businesses in a market with demand uncertainty, while outsource the functional areas of their products to a common contract manufacturer. We develop a game theoretical model under the newsvendor setting and then analyze the equilibrium outcomes. The results show that it is profitable for the two buyers to engage in quality investment activities without worrying too much about spillovers. Our findings provide quality investment decisions for firms under competitive environments, as well as explain the reasons why some firms are willing to invest in shared contract manufacturers even realized investments may potentially benefit their rivals.