Cleaned a warning.
Fixed a memory leak and concurrence problem dealing with the positions extracted from the xml.