South Africa apologizes for anti-immigrant violence