Correctly catch nil, and convert to int before computation
Merge pull request #396 from bcrochet/fix-mtu

Correctly catch nil, and convert to int before computation