We compute the second moments of pion and rho parton distribution functions (PDFs) in lattice QCD with N f = 2 + 1 flavors of improved Wilson fermions. We determine both singlet and nonsinglet flavor combinations and, for the first time, take disconnected contributions fully into account. In the case of the rho, we also calculate the additional contribution arising from the b1 structure function. The numerical analysis includes 26 ensembles, mainly generated by the CLS effort, with pion masses ranging from 420 MeV down to 214 MeV and with 5 different lattice spacings in the range of 0.1 fm to 0.05 fm. This enables us to take the continuum limit, as well as to resolve the quark mass dependencies reliably. Additionally we discuss the contaminations of rho correlation functions by two-pion states.