Preventing overflow in .result, also some padding improvements