From 36b513ccce64dd126e118dd2bbe961f7ad55be37 Mon Sep 17 00:00:00 2001 From: Richard Wilson Date: Tue, 5 Apr 2005 18:52:00 +0000 Subject: [project @ 2005-04-05 18:52:00 by rjw] Fix reading from zero-page. svn path=/import/netsurf/; revision=1601 --- riscos/url_complete.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'riscos') diff --git a/riscos/url_complete.c b/riscos/url_complete.c index 56ae55e7a..33151f3f9 100644 --- a/riscos/url_complete.c +++ b/riscos/url_complete.c @@ -117,7 +117,7 @@ bool ro_gui_url_complete_keypress(struct gui_window *g, int key) { } /* check if we should ignore text changes */ - if (url_complete_keypress_selection >= 0) + if ((url_complete_keypress_selection >= 0) && (url_complete_matches)) ignore_changes = !strcmp(url, url_complete_matches[url_complete_keypress_selection]); @@ -129,8 +129,9 @@ bool ro_gui_url_complete_keypress(struct gui_window *g, int key) { lines = MAXIMUM_VISIBLE_LINES; if (lines > url_complete_matches_available) lines = url_complete_matches_available; - for (i = 0; i < MAXIMUM_VISIBLE_LINES; i++) - url_complete_redraw[i] = url_complete_matches[i]; + if (url_complete_matches) + for (i = 0; i < MAXIMUM_VISIBLE_LINES; i++) + url_complete_redraw[i] = url_complete_matches[i]; /* our selection gets wiped */ error = xwimp_force_redraw(dialog_url_complete, -- cgit v1.2.3