From 90a3d47dcee75fe9c7f0bc562ce19ed98a785e60 Mon Sep 17 00:00:00 2001 From: johncoswell Date: Tue, 3 Oct 2006 01:10:57 +0000 Subject: [PATCH] Check to make sure canvas provided to forced redraw functions is not null. --- src/display/sp-canvas.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/display/sp-canvas.cpp b/src/display/sp-canvas.cpp index 1f89e8bae..1fe577d8e 100644 --- a/src/display/sp-canvas.cpp +++ b/src/display/sp-canvas.cpp @@ -1743,6 +1743,8 @@ sp_canvas_paint_rect (SPCanvas *canvas, int xx0, int yy0, int xx1, int yy1) */ void sp_canvas_force_full_redraw_after_interruptions(SPCanvas *canvas, unsigned int count) { + g_return_if_fail(canvas != NULL); + canvas->forced_redraw_limit = count; canvas->forced_redraw_count = 0; } @@ -1752,6 +1754,8 @@ sp_canvas_force_full_redraw_after_interruptions(SPCanvas *canvas, unsigned int c */ void sp_canvas_end_forced_full_redraws(SPCanvas *canvas) { + g_return_if_fail(canvas != NULL); + canvas->forced_redraw_limit = 0; } -- 2.30.2