check xml for errors and retry
checking argv length to be exactly 2