diff options
author | Daniel Silverstone <dsilvers@netsurf-browser.org> | 2010-04-30 16:06:03 +0000 |
---|---|---|
committer | Daniel Silverstone <dsilvers@netsurf-browser.org> | 2010-04-30 16:06:03 +0000 |
commit | 5e887908b34b804a19b2b7370b0aa358d0e55973 (patch) | |
tree | 68935c8d2fe196a64a17bace1508884d538a5e17 /framebuffer | |
parent | f0237aac922a3ee5b14233fa98baf19df97866ed (diff) | |
download | netsurf-5e887908b34b804a19b2b7370b0aa358d0e55973.tar.gz netsurf-5e887908b34b804a19b2b7370b0aa358d0e55973.tar.bz2 |
Consolidate several 'myrealloc' functions into ns_realloc, rename one which *is* different, thereby eliminating the word 'myrealloc' from the NS codebase
svn path=/trunk/netsurf/; revision=10530
Diffstat (limited to 'framebuffer')
-rw-r--r-- | framebuffer/gui.c | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/framebuffer/gui.c b/framebuffer/gui.c index 10a2b329d..14771ad27 100644 --- a/framebuffer/gui.c +++ b/framebuffer/gui.c @@ -321,17 +321,6 @@ fb_browser_window_redraw(fbtk_widget_t *root, fbtk_widget_t *widget, void *pw) return 0; } -static void *myrealloc(void *ptr, size_t len, void *pw) -{ - if (len == 0) { - free(ptr); - return NULL; - } - - return realloc(ptr, len); -} - - static const char *fename; static int febpp; static int fewidth; @@ -402,7 +391,7 @@ static void gui_init(int argc, char** argv) fb_find_resource(buf, "Aliases", "./framebuffer/res/Aliases"); LOG(("Using '%s' as Aliases file", buf)); - if (hubbub_initialise(buf, myrealloc, NULL) != HUBBUB_OK) + if (hubbub_initialise(buf, ns_realloc, NULL) != HUBBUB_OK) die("Unable to initialise HTML parsing library.\n"); option_core_select_menu = true; @@ -504,7 +493,7 @@ void gui_quit(void) framebuffer_finalise(); /* We don't care if this fails as we're about to exit, anyway */ - hubbub_finalise(myrealloc, NULL); + hubbub_finalise(ns_realloc, NULL); } /* called back when click in browser window */ |