Ensuring file exists before checking size and appending XML extension instead of replacing for dest file