Anvil: Fixed an off-by-one error in the loader.

Fixes #1307.