fix bugs about xml files