It really depends on what you wish to achieve. Yes, you can set it to a larger arbitrary number, or you can just remove the second check completely and let it roll over to a negative number past 0x7FFFFFFF where it will get set to 0 by the first check.
If the reason for the original check was to keep it 5 digits so it will fit in the UI then setting it to 0 for negative numbers and 99999 for anything higher than 99999 seems like a better solution. You can use plain integer numbers for the check, you don't need to convert it to hex.
0xA0000 = 655360 btw.
|