python: fix use-after-free in functions xmlPythonFileReadRaw(), xmlPythonFileRead() with python2. Fixes #910.