Hacker News new | ask | show | jobs
by eqvinox 400 days ago
If strtol reliably sets errno to ERANGE, you're fine (you'll get a compiler warning for "if (aLong < INT_MIN || aLong > INT_MAX) {" though, because it can never be true.)

I have no idea what the cross-platform reliability of strtol() is, regarding errno. Should be fine, I hope.