GNOME Bugzilla – Bug 512841
Crash in expression parser on nullary functions, like pmt()
Last modified: 2018-06-29 22:00:18 UTC
What were you doing when the application crashed? Typed pmt() in the transaction amount Distribution: Unknown Gnome Release: 2.21.2 2007-11-13 (GNOME.Org) BugBuddy Version: 2.20.1 System: Linux 2.6.23.8 #1 PREEMPT Mon Nov 19 14:13:22 PST 2007 i686 X Vendor: The X.Org Foundation X Vendor Release: 70100000 Selinux: No Accessibility: Disabled GTK+ Theme: Clearlooks Icon Theme: gnome Memory status: size: 88133632 vsize: 88133632 resident: 55812096 share: 16322560 rss: 55812096 rss_rlim: 4294967295 CPU usage: start_time: 1201626173 rtime: 1424 utime: 836 stime: 588 cutime:0 cstime: 14 timeout: 0 it_real_value: 0 frequency: 100 Backtrace was generated from '/usr/bin/gnucash' Using host libthread_db library "/lib/libthread_db.so.1". [Thread debugging using libthread_db enabled] [New Thread -1232345408 (LWP 10632)] [New Thread -1264948336 (LWP 10634)] 0xffffe410 in __kernel_vsyscall ()
+ Trace 187221
Thread 1 (Thread -1232345408 (LWP 10632))
----------- .xsession-errors (3772 sec old) --------------------- PluralForm.jsm: Index #1 of '' for value 0 is invalid -- plural rule #1 PluralForm.jsm: Index #1 of '' for value 0 is invalid -- plural rule #1 PluralForm.jsm: Index #1 of '' for value 0 is invalid -- plural rule #1 PluralForm.jsm: Index #1 of '' for value 0 is invalid -- plural rule #1 PluralForm.jsm: Index #1 of '' for value 0 is invalid -- plural rule #1 PluralForm.jsm: Index #1 of '' for value 0 is invalid -- plural rule #1 PluralForm.jsm: Index #1 of '' for value 0 is invalid -- plural rule #1 PluralForm.jsm: Index #1 of '' for value 0 is invalid -- plural rule #1 PluralForm.jsm: Index #1 of '' for value 0 is invalid -- plural rule #1 PluralForm.jsm: Index #1 of '' for value 0 is invalid -- plural rule #1 PluralForm.jsm: Index #1 of '' for value 0 is invalid -- plural rule #1 PluralForm.jsm: Index #1 of '' for value 0 is invalid -- plural rule #1 PluralForm.jsm: Index #1 of '' for value 0 is invalid -- plural rule #1 PluralForm.jsm: Index #1 of '' for value 0 is invalid -- plural rule #1 "/usr/bin/gnucash": not in executable format: File format not recognized --------------------------------------------------
Nice bug, big thanks! I suppose this is due to an expression parser bug that regards pmt() as a unary function with a NULL parameter. It seems to me that the following patch could resolve this issue. Jsled, what do you think?
Created attachment 103998 [details] [review] First try
Well, applied to trunk as r17021. Marking for backport to 2.2.
Applied to branches/2.2 as r17129 for GnuCash 2.2.5.
GnuCash bug tracking has moved to a new Bugzilla host. This bug has been copied to https://bugs.gnucash.org/show_bug.cgi?id=512841. Please update any external references or bookmarks.