google/gumbo-parser — pull request #249 by rgrove (2014-08-28 17:53:20+00:00)
Title: Don't leave semicolons behind after consuming character entities

Character entities such as `Ö` and `À` were being consumed incorrectly, leaving the semicolons behind. This commit fixes those entities and several others with the same problem.

There's [a warning](https://github.com/google/gumbo-parser/blob/1fbc93bdf97dde6b07b67abb29a71d779f533dd8/src/char_ref.c#L54-L55) near the top of `char_ref.c` that explains why this was happening, but unfortunately its instructions weren't followed consistently:

```c
// Versions with the semicolon must come before versions without the semicolon,
// otherwise they'll match the invalid name first and record a parse error.
```

Related: rgrove/sanitize#114