Skip to content

Commit fe64715

Browse files
authored
fix typo
1 parent 84df93e commit fe64715

File tree

1 file changed

+1
-1
lines changed
  • src/content/developers/docs/smart-contracts/security

1 file changed

+1
-1
lines changed

src/content/developers/docs/smart-contracts/security/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -357,7 +357,7 @@ You can also use a [pull payments](https://docs.openzeppelin.com/contracts/4.x/a
357357

358358
An integer overflow occurs when the results of an arithmetic operation falls outside the acceptable range of values, causing it to "roll over" to the lowest representable value. For example, a `uint8` can only store values up to 2^8-1=255. Arithmetic operations that result in values higher than `255` will overflow and reset `uint` to `0`, similar to how the odometer on a car resets to 0 once it reaches the maximum mileage (999999).
359359

360-
Integer underflows happen for similar reasons: the the results of an arithmetic operation falls below the acceptable range. Say you tried decrementing `0` in a `uint8`, the result would simply roll over to the maximum representable value (`255`).
360+
Integer underflows happen for similar reasons: the results of an arithmetic operation falls below the acceptable range. Say you tried decrementing `0` in a `uint8`, the result would simply roll over to the maximum representable value (`255`).
361361

362362
Both integer overflows and underflows can lead to unexpected changes to a contract’s state variables and result in unplanned execution. Below is an example showing how an attacker can exploit arithmetic overflow in a smart contract to perform an invalid operation:
363363

0 commit comments

Comments
 (0)