After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 360672 - Crash when pasting from another gnumeric via clipboard
Crash when pasting from another gnumeric via clipboard
Status: RESOLVED FIXED
Product: Gnumeric
Classification: Applications
Component: GUI
git master
Other All
: Normal major
: ---
Assigned To: Jody Goldberg
Jody Goldberg
Depends on:
Blocks:
 
 
Reported: 2006-10-08 15:37 UTC by Jon Kåre Hellan
Modified: 2006-10-09 00:36 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Jon Kåre Hellan 2006-10-08 15:37:05 UTC
Enter the following in gnumeric 1:
A1: 1
A2: 2
A3: =A1+A2

Select cells A2:A3 and select Edit/Copy.

In gnumeric 2, select Edit/Paste. Gnumeric 2 segfaults. 
Backtrace:

  • #0 cb_max_cell_height
    at sheet.c line 1674
  • #1 sheet_foreach_cell_in_range
    at sheet.c line 2844
  • #2 sheet_row_size_fit_pixels
    at sheet.c line 1725
  • #3 cb_autofit_row
    at colrow.c line 684
  • #4 colrow_foreach
    at colrow.c line 171
  • #5 colrow_autofit
    at colrow.c line 753

See also bug 360666
Comment 1 Morten Welinder 2006-10-08 21:57:46 UTC
Good catch.

The problem is that cell->value is NULL which is a big no-no.  It looks
like clipboard.c fails to set the CELL_HAS_NEW_EXPR flag.
Comment 2 Morten Welinder 2006-10-09 00:36:31 UTC
Fixed in the development version. The fix will be available in the next major release. Thank you for your bug report.

This patch happens to fix this crash and has been committed.  More bugs
conspired to make the crash, though.  We should not get a NULL value
here.  That has not yet been tracked down.


2006-10-08  Morten Welinder  <terra@gnome.org>

	* src/cell.c (cell_set_expr_and_value): Set CELL_HAS_NEW_EXPR just
	like cell_set_expr_internal.  Fixes #360672.