summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndrew Sidwell <andy@entai.co.uk>2008-08-10 16:48:32 +0000
committerAndrew Sidwell <andy@entai.co.uk>2008-08-10 16:48:32 +0000
commit4aef3c775e93d5add0277941fe0ecccc91d4ccb3 (patch)
treefa52e2dad3bdb51f28e48ecfd15e4d1dc8ba6bb7 /src
parent5eb5ec3682ba75cec9616039c60987eeee26e5ee (diff)
downloadlibhubbub-4aef3c775e93d5add0277941fe0ecccc91d4ccb3.tar.gz
libhubbub-4aef3c775e93d5add0277941fe0ecccc91d4ccb3.tar.bz2
Make the encoding change callback send the textual name rather than the mibenum value.
svn path=/trunk/hubbub/; revision=4992
Diffstat (limited to 'src')
-rw-r--r--src/treebuilder/in_head.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/treebuilder/in_head.c b/src/treebuilder/in_head.c
index ddb7453..88fcff5 100644
--- a/src/treebuilder/in_head.c
+++ b/src/treebuilder/in_head.c
@@ -62,16 +62,20 @@ static hubbub_error process_meta_in_head(hubbub_treebuilder *treebuilder,
if (charset_enc != 0) {
if (treebuilder->tree_handler->encoding_change) {
+ const char *name = parserutils_charset_mibenum_to_name(
+ charset_enc);
treebuilder->tree_handler->encoding_change(
treebuilder->tree_handler->ctx,
- charset_enc);
+ name);
}
return HUBBUB_ENCODINGCHANGE;
} else if (content_type_enc != 0) {
if (treebuilder->tree_handler->encoding_change) {
+ const char *name = parserutils_charset_mibenum_to_name(
+ content_type_enc);
treebuilder->tree_handler->encoding_change(
treebuilder->tree_handler->ctx,
- content_type_enc);
+ name);
}
return HUBBUB_ENCODINGCHANGE;
}