Zentyal/sogo — pull request #36 by blaxter (2014-08-25 16:45:21+00:00)
Title: RTF Parser: fix crah parsing font table

Zentyal crashreports related with this: 1628, 1654, 1849, 2089, 2090, 2125, 2139 from the manually triaged subset, probably it'll be a lot more. c&p commit message

---

oc-rtf: control words can also have a space before next tag

This was causing to parse a single space as an empty control
word with length 0, which was the source of several crashes.

Example:

\f0\fbidi \fcharset0
--------^

font index is 0, font family is bidi but when parsing charset we were
assuming control word was '' instead of 'charset0'.

This only fixes the crashes, the parseFontTable function works quite
awful right now.