This is a similar problem to one that was earlier fixed in MySQL-5.0 under terms of:
Bug#27586 Wrong autoinc value assigned by LOAD DATA in the NO_AUTO_VALUE_ON_ZERO mode
Now for LOAD XML instead of LOAD DATA.
I put a file MYSQL_HOME_DIR/test/t1.xml with this content:
and run this script:
It returns the following data:
The auto-increment value for the second record is wrong. It should be 2 rather than 0.