-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
return: fix range warn for sizeof(long)==sizeof(int) (re: b90b8cd)
The integer overflow check was based on 'long' being a wider integer type than 'int', but on 32-bit Linux (at least), they are the same, so the expected out-of-range warning and 128 exit status didn't materialise. src/cmd/ksh93/bltins/cflow.c: b_return(): - Use intmax_t instead of long. - Don't bother with the check where sizeof(intmax_t)==sizeof(int) (generally ancient systems without 'long long'). - Tweaks for code legibility.
- Loading branch information
Showing
3 changed files
with
28 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters