Stability of certain nonlinear differential equations