Fixed xml ouput generation for python 2.7.5

The xml was being outputted with newlines before and after each value