pXmlBuffer is not null terminated
Merge pull request #4074 from ledyba/parent_master

pXmlBuffer is not null terminated(to master  branch)