From 768ef5c60bd59daa227910c68f4b829db480d6ac Mon Sep 17 00:00:00 2001 From: Jeffrey Stedfast Date: Wed, 11 Jul 2001 23:56:31 +0000 Subject: New function to extract a meta-tag charset value if it exists. 2001-07-11 Jeffrey Stedfast * camel-mime-part-utils.c (extract_metatag_charset): New function to extract a meta-tag charset value if it exists. (simple_data_wrapper_construct_from_parser): Along the same lines as the code I previously ripped out, but this time use the mime-parser's seek ability to help us along. Currently I read up to a 2k buffer size - this is probably overkill, 1k is probably plenty. * camel-mime-utils.c (html_meta_param_list_decode): When we get to an `=', we must skip past it before trying to grab the param value. duh. svn path=/trunk/; revision=11021 --- camel/camel-mime-utils.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'camel/camel-mime-utils.c') diff --git a/camel/camel-mime-utils.c b/camel/camel-mime-utils.c index b87824e862..eb228cd748 100644 --- a/camel/camel-mime-utils.c +++ b/camel/camel-mime-utils.c @@ -1685,7 +1685,7 @@ header_decode_quoted_string(const char **in) } *outptr++ = c; } - *outptr = 0; + *outptr = '\0'; } *in = inptr; return out; @@ -2723,6 +2723,7 @@ header_param_list_decode(const char *in) struct _header_param * html_meta_param_list_decode (const char *in, int inlen) { + /* example: */ struct _header_param *params = NULL, *last = NULL; const char *inptr, *inend; @@ -2753,6 +2754,7 @@ html_meta_param_list_decode (const char *in, int inlen) break; } + inptr++; value = header_decode_value (&inptr); header_decode_lwsp (&inptr); -- cgit v1.2.3