Bug in the register value entry

Conrad Canterford conrad@mail.watersprite.com.au
04 Jun 2002 13:53:42 +1000

On Thu, 2002-04-18 at 12:02, Conrad Canterford wrote:
> In gnucash 1.6.6, locally compiled, guile-1.4 and g-wrap 1.1.9.

I have now upgraded to g-wrap 1.1.11, but I still see:

> I have found a problem with the data entry into the debit/credit fields
> of the register. If I enter the simple arithmetic statement:
> 22.32*2+16.8+34.2*2+18.81+85.44-42.72+13.32+15.48+23.4+115.4
> into the Debit field, the result I get back (after some computational
> burden on the processor) is not correct and in all 3 instances I've seen
> so far has been a negative number (two quite large, one small). I
> believe that it is negative because it ends up in the credit field, even
> though I entered the above into the debit field.
> I'm guessing we're getting memory corruption in one of the register
> structures, as any attempts to modify the values were giving various and
> different results. Deleting the split and re-entering it without the
> subtraction component in it worked. I could then do the subtraction
> seperately without problems.

The two times I encountered this today (two seperate transactions) did
not involve a subtraction operation. Both were, however, long strings of
simple additions. Is it possible that we're getting a buffer overflow
Dave_p, if you're reading this, or perhaps hampton since I know you've
looked at some of this code, what possible external dependancies relate
to this code that might explain why I get the problem, but other people
Note that it does appear to be intermittant - I do this sort of thing on
a regular basis, and it does not happen every time (though it is far too
frequent for me to just shrug about it).

Conrad Canterford  (conrad@mail.watersprite.com.au)
Water Sprite Pty Ltd   |  url - http://www.watersprite.com.au/
GPO Box 355,           |  - Australian Tour and Event Management (ATEM)
Canberra, ACT 2601     |  - Ticketing Division.
Mobile: +61 402 697054 |  - Catering Services Division.