Fix double fclose.
Add a few more comments.
Stop parsing if a fatal error occurs.
Merge pull request #1134 from fontforge/scripting_hunt_1

Fix double fclose and segfault and add comments in the scripting engine.