aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/e-table/e-table.c
diff options
context:
space:
mode:
Diffstat (limited to 'widgets/e-table/e-table.c')
-rw-r--r--widgets/e-table/e-table.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/widgets/e-table/e-table.c b/widgets/e-table/e-table.c
index 26cb1504b9..7906ad877d 100644
--- a/widgets/e-table/e-table.c
+++ b/widgets/e-table/e-table.c
@@ -407,6 +407,7 @@ et_table_cell_changed (ETableModel *table_model, int view_col, int row, ETable *
static void
et_table_row_inserted (ETableModel *table_model, int row, ETable *et)
{
+ /* This number has already been decremented. */
int row_count = e_table_model_row_count(table_model);
if (!et->need_rebuild) {
if (row != row_count - 1)
@@ -421,7 +422,7 @@ et_table_row_deleted (ETableModel *table_model, int row, ETable *et)
int row_count = e_table_model_row_count(table_model);
if (!et->need_rebuild) {
e_table_group_remove (et->group, row);
- if (row != row_count - 1)
+ if (row != row_count)
e_table_group_decrement(et->group, row, 1);
}
}