diff options
author | Don Scorgie <dscorgie@src.gnome.org> | 2007-11-07 19:37:22 +0000 |
---|---|---|
committer | Don Scorgie <dscorgie@src.gnome.org> | 2007-11-07 19:37:22 +0000 |
commit | 5e5041f279041963b62b8a47554bdd1000a8fcbf (patch) | |
tree | cdf4d28604a7c6474a8e4c47b325a453de4d7f75 | |
parent | ce5ed53931636a4e2a1803280972a80dd509af42 (diff) | |
download | yelp-5e5041f279041963b62b8a47554bdd1000a8fcbf.tar.gz |
x-yelp-toc uri scheme frags now strip leading '#' and '?'s (bug #482290)
* src/yelp-utils.c:
x-yelp-toc uri scheme frags now strip leading '#'
and '?'s (bug #482290)
svn path=/trunk/; revision=2988
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | src/yelp-utils.c | 5 |
2 files changed, 8 insertions, 1 deletions
@@ -1,5 +1,9 @@ 2007-11-07 Don Scorgie <dscorgie@svn.gnome.org> + * src/yelp-utils.c: + x-yelp-toc uri scheme frags now strip leading '#' + and '?'s (bug #482290) + * src/yelp-window.c: Fix debug build (bug #492882) diff --git a/src/yelp-utils.c b/src/yelp-utils.c index 46a8bf8a..1a9da13f 100644 --- a/src/yelp-utils.c +++ b/src/yelp-utils.c @@ -387,7 +387,10 @@ yelp_uri_resolve (gchar *uri, gchar **result, gchar **section) } else if (!strncmp (uri, "x-yelp-toc:", 11)) { ret = YELP_RRN_TYPE_TOC; if (strlen (uri) > 11) { - *section = g_strdup (&uri[11]); + gint frag = 11; + while (uri[frag] == '#' || uri[frag] == '?') + frag++; + *section = g_strdup (&uri[frag]); } else { *section = g_strdup("index"); } |