  Our Universe is nearly spatially flat, but this does not mean that it is
exactly spatially flat. In this paper we derive general quadratic actions for
cosmological perturbations in non-flat models from the Horndeski theory. This
allows us to study how the spatial curvature influences the behavior of
cosmological perturbations in the early universe described by some general
scalar-tensor theory. We show that a tiny spatial curvature at the onset of
inflation is unlikely to yield large (or ${\cal O}(1)$) effects on the
primordial spectra even if one modifies gravity. We also argue that
non-singular cosmological solutions in the Horndeski theory are unstable in
spatially open cases as well as in flat cases.
