Fixes #2
Merge pull request #3 from Cheesebaron/patch-1

Guard against edge cases caused by layout inflation