diff options
author | John Mark Bell <jmb@netsurf-browser.org> | 2008-08-04 09:12:18 +0000 |
---|---|---|
committer | John Mark Bell <jmb@netsurf-browser.org> | 2008-08-04 09:12:18 +0000 |
commit | d60ec588f8e5e4cb97e31e6f8c40c7b9a1c2ba4c (patch) | |
tree | fd39d2cfb63feabb1adf54aa77408aa149d8373f | |
parent | f88f034a4f9e0db06a64326198e19b2ef5a0283f (diff) | |
download | libhubbub-d60ec588f8e5e4cb97e31e6f8c40c7b9a1c2ba4c.tar.gz libhubbub-d60ec588f8e5e4cb97e31e6f8c40c7b9a1c2ba4c.tar.bz2 |
Really fix handling of entities in attributes
svn path=/trunk/hubbub/; revision=4894
-rw-r--r-- | src/tokeniser/tokeniser.c | 2 | ||||
-rw-r--r-- | test/data/tree-construction/regression.dat | 10 |
2 files changed, 11 insertions, 1 deletions
diff --git a/src/tokeniser/tokeniser.c b/src/tokeniser/tokeniser.c index 54ad118..a79d59e 100644 --- a/src/tokeniser/tokeniser.c +++ b/src/tokeniser/tokeniser.c @@ -2811,7 +2811,7 @@ bool hubbub_tokeniser_handle_named_entity(hubbub_tokeniser *tokeniser) return false; cptr = parserutils_inputstream_peek(tokeniser->input, - ctx->match_entity.offset + ctx->match_entity.length, + ctx->match_entity.offset + ctx->match_entity.length - 1, &len); c = CHAR(cptr); diff --git a/test/data/tree-construction/regression.dat b/test/data/tree-construction/regression.dat index bb99546..1423ea7 100644 --- a/test/data/tree-construction/regression.dat +++ b/test/data/tree-construction/regression.dat @@ -29,3 +29,13 @@ | <center> | <font> +#data +<a href="a&b&c">Foo</a> +#errors +#document +| <html> +| <head> +| <body> +| <a> +| href="a&b&c" +| "Foo" |