A weak extension theorem for inhomogeneous differential equations