aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/table/e-cell-toggle.c
diff options
context:
space:
mode:
Diffstat (limited to 'widgets/table/e-cell-toggle.c')
-rw-r--r--widgets/table/e-cell-toggle.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/widgets/table/e-cell-toggle.c b/widgets/table/e-cell-toggle.c
index f334c3f6ca..34e8a8b76d 100644
--- a/widgets/table/e-cell-toggle.c
+++ b/widgets/table/e-cell-toggle.c
@@ -201,7 +201,7 @@ etog_draw (ECellView *ecell_view, GdkDrawable *drawable,
selected = flags & E_CELL_SELECTED;
- if (value >= toggle->n_states){
+ if (value < 0 || value >= toggle->n_states){
g_warning ("Value from the table model is %d, the states we support are [0..%d)\n",
value, toggle->n_states);
return;