Magic numbers in the neutron-rich oxygen isotopes