Direct solution of the random-phase approximation eigenvalue equations for two-electron systems