We introduce notions of nearly good relations and N-sticky modulo a relation as tools for proving that spaces are D-spaces. As a corollary to general results about such relations, we show that Cp(X) is hereditarily a D-space whenever X is a Lindelöf Σ-space. This answers a question of Matveev, and improves a result of Buzyakova, who proved the same result for X compact. We also prove that if a ...