summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Drake <tlsa@netsurf-browser.org>2014-05-26 11:29:03 +0100
committerMichael Drake <tlsa@netsurf-browser.org>2014-05-26 11:29:03 +0100
commitcb0ae229491ee12293f066e99939e11d1b9daed4 (patch)
tree75742135e9815b9282d2b77e39cf752ea3f96546
parent82bc40350a3bff0feb0e975bf1b8e423febab63e (diff)
downloadnetsurf-cb0ae229491ee12293f066e99939e11d1b9daed4.tar.gz
netsurf-cb0ae229491ee12293f066e99939e11d1b9daed4.tar.bz2
Improve error handling.
-rw-r--r--riscos/gui/progress_bar.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/riscos/gui/progress_bar.c b/riscos/gui/progress_bar.c
index cd4b08929..09b3edb45 100644
--- a/riscos/gui/progress_bar.c
+++ b/riscos/gui/progress_bar.c
@@ -328,6 +328,11 @@ void ro_gui_progress_bar_update(struct progress_bar *pb, int width, int height)
redraw.box = pb->visible;
redraw.box.x0 = cur.x1;
error = xwimp_update_window(&redraw, &more);
+ if (error) {
+ LOG(("Error getting update window: 0x%x: %s",
+ error->errnum, error->errmess));
+ return;
+ }
if (more)
ro_gui_progress_bar_redraw_window(&redraw, pb);
}
@@ -383,6 +388,10 @@ void ro_gui_progress_bar_animate(void *p)
redraw.w = pb->w;
redraw.box = pb->visible;
error = xwimp_update_window(&redraw, &more);
+ if (error != NULL) {
+ LOG(("Error getting update window: '%s'", error->errmess));
+ return;
+ }
if (more)
ro_gui_progress_bar_redraw_window(&redraw, pb);
}