XMLSerializer.h: Fixed Null pointer problems