"unsigned integer value" functions fail for large numbers

Bug #181763 reported by Andy Owen
4
Affects Status Importance Assigned to Milestone
GCalctool
Fix Released
Medium
gcalctool (Ubuntu)
Fix Released
Low
Ubuntu Desktop Bugs

Bug Description

Binary package hint: gcalctool

The "&16" and "&32" functions both fail for large inputs:

u16(11111111111111111111)
u32(11111111111111111111)

Both evaluate to 0 (and their least significant bit is 0)

But doing the "near" equivalent (which stuffs up for negatives and behaves differently for non-integer inputs) works:

11111111111111111111 Mod 65536 = 29127
11111111111111111111 Mod 4294967291 = 3098111297

ProblemType: Bug
Architecture: i386
Date: Thu Jan 10 23:57:29 2008
DistroRelease: Ubuntu 7.10
ExecutablePath: /usr/bin/gcalctool
NonfreeKernelModules: vmnet vmmon nvidia
Package: gcalctool 5.20.2-0ubuntu1
PackageArchitecture: i386
ProcCmdline: gcalctool
ProcCwd: /home/andy
ProcEnviron:
 PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
 LANG=en_AU.UTF-8
 SHELL=/usr/bin/zsh
SourcePackage: gcalctool
Uname: Linux chicken 2.6.22-14-generic #1 SMP Tue Dec 18 08:02:57 UTC 2007 i686 GNU/Linux

Tags: apport-bug

Related branches

Revision history for this message
Andy Owen (the-new-andy) wrote :
Revision history for this message
Nicolas Joyard (joyard-nicolas) wrote :

Thanks for the bug report. Reproduced here.

Changed in gcalctool:
status: New → Confirmed
Revision history for this message
Pedro Villavicencio (pedro) wrote :

Thanks for your bug report. This bug has been reported to the developers of the software. You can track it and make comments here: http://bugzilla.gnome.org/show_bug.cgi?id=509988

Changed in gcalctool:
assignee: nobody → desktop-bugs
importance: Undecided → Low
status: Confirmed → Triaged
Changed in gcalctool:
status: Unknown → Confirmed
Changed in gcalctool:
status: Confirmed → Fix Released
Revision history for this message
Pedro Villavicencio (pedro) wrote :

this has been fixed upstream already, thanks for reporting.

Changed in gcalctool:
status: Triaged → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gcalctool - 5.24.2-0ubuntu1

---------------
gcalctool (5.24.2-0ubuntu1) jaunty; urgency=low

  * New upstream version (LP: #302915).
    - Remember setting to ignore change mode warning between instance
    (LP: #281541).
    - Removed double conversion in boolean and 32 bit and 16 bit to handle
      larger numbers (LP: #181763).
    - Update on the build-depends from the 2.11.6 to 2.14.0
      + Update of debian/configure.in and debian/configure to reflect that.
      + Update of debian/patches/01_lpi.patch since it patches
        debian/configure.in.
      + Update of debian/patches/02_autoconf.patch since it patches
        debian/configure.

 -- Christophe Sauthier <email address hidden> Thu, 27 Nov 2008 20:46:19 +0100

Changed in gcalctool:
status: Fix Committed → Fix Released
Changed in gcalctool:
importance: Unknown → Medium
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.