[fontloader] patch glyph reorganization to avoid error

This is a preliminary fix for https://github.com/lualatex/luaotfload/issues/248

It adds additional null checks, thereby suppressing the symptoms.
However, the real solution would probably have to tackle the actual
cause of the holes in the ``specification`` table in the first place.
Merge pull request #249 from phi-gamma/2.5-fixes

[fontloader] patch glyph reorganization to avoid error