xml2php changed to catch an exception