[gnumeric] Paste: be a bit paranoid.



commit ef3186171ddb26cc85d2a9bcd90d2fffdf0720bf
Author: Morten Welinder <terra gnome org>
Date:   Mon Apr 16 15:44:42 2018 -0400

    Paste: be a bit paranoid.

 src/gui-clipboard.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)
---
diff --git a/src/gui-clipboard.c b/src/gui-clipboard.c
index 6f323ef..15ea967 100644
--- a/src/gui-clipboard.c
+++ b/src/gui-clipboard.c
@@ -342,6 +342,11 @@ table_cellregion_read (WorkbookControl *wbc, char const *reader_id,
                                (tmpsheet, &r, &fullr, col_defaults);
 
                        g_free (col_defaults);
+
+                       // Just in case there was absolutely nothing in
+                       // tmpsheet:
+                       if (r.start.col > r.end.col)
+                               range_init (&r, 0, 0, 0, 0);
                }
                ret = clipboard_copy_range (tmpsheet, &r);
        }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]