diff options
author | Vincent Sanders <vince@netsurf-browser.org> | 2013-05-27 00:32:08 +0100 |
---|---|---|
committer | Vincent Sanders <vince@netsurf-browser.org> | 2013-05-28 14:16:11 +0100 |
commit | 1502b08925c227152c3064b221af7a5659ac00cc (patch) | |
tree | 05f1e032db9ca2e4ba7f57783c639c64a15f873e | |
parent | ea0f541309cc7d3251c62cf02841bd8fcb2c2571 (diff) | |
download | netsurf-1502b08925c227152c3064b221af7a5659ac00cc.tar.gz netsurf-1502b08925c227152c3064b221af7a5659ac00cc.tar.bz2 |
move option init out of netsurf_init
-rw-r--r-- | content/fetchers/about.c | 7 | ||||
-rw-r--r-- | desktop/netsurf.c | 15 | ||||
-rw-r--r-- | desktop/netsurf.h | 2 |
3 files changed, 8 insertions, 16 deletions
diff --git a/content/fetchers/about.c b/content/fetchers/about.c index 85723e86a..ee2ea5477 100644 --- a/content/fetchers/about.c +++ b/content/fetchers/about.c @@ -334,9 +334,10 @@ static bool fetch_about_config_handler(struct fetch_about_context *ctx) "<tr><th></th><th></th><th></th></tr>\n"); do { - res = nsoption_snoptionf(buffer + slen, sizeof buffer - slen, - opt_loop, - "<tr><th>%k</th><td>%t</td><td>%V</td></tr>\n"); + res = nsoption_snoptionf(buffer + slen, + sizeof buffer - slen, + opt_loop, + "<tr><th>%k</th><td>%t</td><td>%V</td></tr>\n"); if (res <= 0) break; /* last option */ diff --git a/desktop/netsurf.c b/desktop/netsurf.c index f63969b76..fa026dc6a 100644 --- a/desktop/netsurf.c +++ b/desktop/netsurf.c @@ -115,10 +115,7 @@ static nserror netsurf_llcache_query_handler(const llcache_query *query, * Initialise components used by gui NetSurf. */ -nserror netsurf_init(int *pargc, - char ***pargv, - const char *options, - const char *messages) +nserror netsurf_init(const char *messages) { nserror error; struct utsname utsname; @@ -143,7 +140,7 @@ nserror netsurf_init(int *pargc, signal(SIGPIPE, SIG_IGN); #endif - LOG(("version '%s'", netsurf_version)); + LOG(("NetSurf version '%s'", netsurf_version)); if (uname(&utsname) < 0) LOG(("Failed to extract machine information")); else @@ -152,10 +149,6 @@ nserror netsurf_init(int *pargc, utsname.nodename, utsname.release, utsname.version, utsname.machine)); - LOG(("Using '%s' for Options file", options)); - nsoption_read(options); - gui_options_init_defaults(); - messages_load(messages); /* corestrings init */ @@ -175,7 +168,7 @@ nserror netsurf_init(int *pargc, /* image cache is 25% of total memory cache size */ image_cache_parameters.limit = (hlcache_parameters.limit * 25) / 100; - /* image cache hysteresis is 20% of teh image cache size */ + /* image cache hysteresis is 20% of the image cache size */ image_cache_parameters.hysteresis = (image_cache_parameters.limit * 20) / 100; /* account for image cache use from total */ @@ -220,8 +213,6 @@ nserror netsurf_init(int *pargc, /* Initialize system colours */ gui_system_colour_init(); - nsoption_commandline(pargc, *pargv); - js_initialise(); return ret; diff --git a/desktop/netsurf.h b/desktop/netsurf.h index 10c1e00e3..bfdb647ff 100644 --- a/desktop/netsurf.h +++ b/desktop/netsurf.h @@ -28,7 +28,7 @@ extern const char * const netsurf_version; extern const int netsurf_version_major; extern const int netsurf_version_minor; -nserror netsurf_init(int *argc, char ***argv, const char *options, const char *messages); +nserror netsurf_init(const char *messages); extern void netsurf_exit(void); extern int netsurf_main_loop(void); |