I have been doing some bug hunting on etherscan.io and have come across many contracts with this kind of code. Specifically, the ones that don't use safe math library, are older then solidity 0.8, and don't explicitly check for overflows. Could someone please tell me if this code is okay and safe or should it be flagged in an audit as vulnerable. If it is vulnerable what is the severity and can it be used to compromise the token balances of the smart contract.
function transfer(address _to, uint256 _value) returns (bool success) {
require(balances[msg.sender] >= _value);
balances[msg.sender] -= _value;
balances[_to] += _value;
Transfer(msg.sender, _to, _value);
return true;
}
Thanks in advance.