Fix infinite loop bug.
auto merge of #882 : sammykim/servo/infinite-loop, r=metajack

To reproduce:

```html
<span style="font-size: 128px">abc</span>
```