From 7e7e1f6ed33198102e88cf42a181608269e0c289 Mon Sep 17 00:00:00 2001 From: Michael Drake Date: Tue, 27 Sep 2011 12:08:23 +0000 Subject: Squash erroneous warnings abuout uninitalised variable use from gcc 3.4.6. svn path=/trunk/netsurf/; revision=12901 --- utils/nsurl.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) (limited to 'utils') diff --git a/utils/nsurl.c b/utils/nsurl.c index f49759df6..c6fd24425 100644 --- a/utils/nsurl.c +++ b/utils/nsurl.c @@ -459,8 +459,8 @@ static nserror nsurl__create_from_section(const char const *url_s, nsurl *url) { int ascii_offset; - int start; - int end; + int start = 0; + int end = 0; const char *pos; const char *pos_url_s; char *norm_start = pos_norm; @@ -657,7 +657,7 @@ static nserror nsurl__create_from_section(const char const *url_s, case URL_HOST: if (length != 0) { - size_t colon; + size_t colon = 0; char *sec_start = norm_start; if (pegs->at < pegs->colon_first && pegs->colon_last == pegs->authority) { @@ -1001,14 +1001,14 @@ bool nsurl_compare(const nsurl *url1, const nsurl *url2, nsurl_component parts) nserror nsurl_get(const nsurl *url, nsurl_component parts, char **url_s, size_t *url_l) { - size_t scheme; - size_t username; - size_t password; - size_t host; - size_t port; - size_t path; - size_t query; - size_t fragment; + size_t scheme = 0; + size_t username = 0; + size_t password = 0; + size_t host = 0; + size_t port = 0; + size_t path = 0; + size_t query = 0; + size_t fragment = 0; char *pos; enum { NSURL_F_SCHEME = (1 << 0), -- cgit v1.2.3