GNOME Bugzilla – Bug 477417
gnumeric crashed with SIGSEGV in gnm_filter_combo_apply()
Last modified: 2007-09-18 17:31:31 UTC
Steps to reproduce: This was reported on Launchpad : https://bugs.launchpad.net/ubuntu/+source/gnumeric/+bug/139702 by : https://bugs.edge.launchpad.net/~perchrh-malone 1. get http://launchpadlibrarian.net/9284671/auctiondata.gnumeric 2. open it 3. do either of the following: a) Press the save button OR b) Try to change the filter setting in the autofilter in sheet 1, setting e.g. skill header to value 10 I couldn't reproduce it, but it happens every time for the original reporter. Stack trace:
+ Trace 163270
Other information: THis might alos be useful for you : http://launchpadlibrarian.net/9284679/ThreadStacktrace.txt http://launchpadlibrarian.net/9284680/StacktraceSource.txt
No crash for me on i86. Stack trace seems to be from 64-bit. That shouldn't matter, but I'll test later.
We could use a few preconditions in gnm_filter_combo_apply, though.
No crash for me on amd64 either
Can you replicate this without optimization?
Also, does this happen with default theme? Certain themes, like "Industrial", are known to corrupt memory.
What do you mean by without optimization ?
He means that the gnumeric binary was compiled with optimization on ("-O2" probably) and that debug information was stripped off. Both make it hard to make sense of the back trace. From the disassembly I am guessing that the crash is happening near the end of filter_expr_init.
Ok thank you. I have some news, an interesting one : the file the original reporter gave was not the crashing file, that's why no one could reproduce it ! The right file : http://launchpadlibrarian.net/9322198/transfer-data.gnumeric I can reproduce the crash this time, no matter what the gtk theme is. It can't be a gutsy regression has it also happens with gnumeric 1.7.8-0ubuntu1 in feisty. I'm going to build the package without optimization to see if the stacktrace has more details.
Confirmed.
This problem has been fixed in the development version. The fix will be available in the next major software release. Thank you for your bug report.
Morten Welinder : When will the next version be released ? For Gnome 2.20?
I don't know, but I wouldn't count on it. You might want to apply this simple patch if you plan to snapshot for a release. (It should apply against anything recent.) Index: src/xml-sax-read.c =================================================================== --- src/xml-sax-read.c (revision 15900) +++ src/xml-sax-read.c (revision 15901) @@ -1869,9 +1869,11 @@ v0 = value_new_from_string (vtype0, val0, NULL, FALSE); if (val1 != NULL && vtype1 != VALUE_EMPTY) v1 = value_new_from_string (vtype1, val1, NULL, FALSE); - if (v0 != NULL) + if (v0 && v1) cond = gnm_filter_condition_new_double ( op0, v0, is_and, op1, v1); + else if (v0) + cond = gnm_filter_condition_new_single (op0, v0); } else if (0 == g_ascii_strcasecmp (type, "blanks")) { cond = gnm_filter_condition_new_single ( GNM_FILTER_OP_BLANKS, NULL);
Morten Welinder : Thank you very much, I will try to get this patch applied.