Fix Coverity defects.
Merge pull request #1778 from fontforge/coverity_fixes_20141007_2

Fix Coverity defects.