diff options
author | James Bursa <james@netsurf-browser.org> | 2004-05-08 20:44:00 +0000 |
---|---|---|
committer | James Bursa <james@netsurf-browser.org> | 2004-05-08 20:44:00 +0000 |
commit | 29340cf8c8e2fe2f0fe8155e45940da29c37b79e (patch) | |
tree | 8cfc858e6e92268eab8da3e5ed8bcf04e2199b8f /riscos/download.c | |
parent | 7356aa96c9c2332b9d3fe35f8e48b2c403620b08 (diff) | |
download | netsurf-29340cf8c8e2fe2f0fe8155e45940da29c37b79e.tar.gz netsurf-29340cf8c8e2fe2f0fe8155e45940da29c37b79e.tar.bz2 |
[project @ 2004-05-08 20:44:00 by bursa]
Break out ro_gui_dialog_load_template(). Replace xcalloc() with malloc() and add some error handling.
svn path=/import/netsurf/; revision=844
Diffstat (limited to 'riscos/download.c')
-rw-r--r-- | riscos/download.c | 16 |
1 files changed, 1 insertions, 15 deletions
diff --git a/riscos/download.c b/riscos/download.c index 6dedaa59e..6ddc0bcaf 100644 --- a/riscos/download.c +++ b/riscos/download.c @@ -31,21 +31,7 @@ static void ro_gui_download_leaf(const char *url, char *leaf); void ro_gui_download_init(void) { - char name[] = "download"; - int context, window_size, data_size; - char *data; - - /* find required buffer sizes */ - context = wimp_load_template(wimp_GET_SIZE, 0, 0, wimp_NO_FONTS, - name, 0, &window_size, &data_size); - assert(context != 0); - - download_template = xcalloc((unsigned int) window_size, 1); - data = xcalloc((unsigned int) data_size, 1); - - /* load */ - wimp_load_template(download_template, data, data + data_size, - wimp_NO_FONTS, name, 0, 0, 0); + download_template = ro_gui_dialog_load_template("download"); } |