Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: exim: dev
[Bug 1112] New: ${eval:INT_MIN/-1} gives SIGFPE
 

Index | Next | Previous | View Flat


pdp at exim

May 7, 2011, 4:45 PM


Views: 219
Permalink
[Bug 1112] New: ${eval:INT_MIN/-1} gives SIGFPE

------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=1112
Summary: ${eval:INT_MIN/-1} gives SIGFPE
Product: Exim
Version: 4.76 RC1
Platform: x86-64
OS/Version: All
Status: NEW
Severity: bug
Priority: medium
Component: String expansion
AssignedTo: pdp [at] exim
ReportedBy: pdp [at] exim
CC: exim-dev [at] exim


In zsh-workers/29178 Jon Mayo reported that zsh gets a SIGFPE with:
echo $[-9223372036854775808/-1]

In light of the recent /0 issue in bug 1102, I investigated if Exim has a
similar issue. It does, using INT_MIN instead of LLONG_MIN.

% exim -be
> ${eval:0x7fffffff}
2147483647
> ${eval:-0x7fffffff}
-2147483647
> ${eval:-0x7fffffff-1}
-2147483648
> ${eval:-0x7fffffff-2}
2147483647
> ${eval:-2147483648/-1}
zsh: floating point exception exim -be

Crap.

In the zsh-workers thread, when discussing whether or not mod should be handled
too (as we did in a follow-up within bug 1102) Mikael Magnusson noted "I am
told that only division will generate an exception on x86"; that might be
constrained to the llong integers, since:

% exim -be
> ${eval:-2147483648%-1}
zsh: floating point exception exim -be


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email

--
## List details at https://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##

Subject User Time
[Bug 1112] New: ${eval:INT_MIN/-1} gives SIGFPE pdp at exim May 7, 2011, 4:45 PM

  Index | Next | Previous | View Flat
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.