[mod-xhtml-neg-cvs] mod_xhtml_neg mod_xhtml_neg.c,1.24,1.25
Brought to you by:
run2000
From: <ru...@us...> - 2004-03-25 10:14:42
|
Update of /cvsroot/mod-xhtml-neg/mod_xhtml_neg In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24933 Modified Files: mod_xhtml_neg.c Log Message: Minor const correctness fixes and other changes. Index: mod_xhtml_neg.c =================================================================== RCS file: /cvsroot/mod-xhtml-neg/mod_xhtml_neg/mod_xhtml_neg.c,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -d -r1.24 -r1.25 *** mod_xhtml_neg.c 25 Mar 2004 09:41:09 -0000 1.24 --- mod_xhtml_neg.c 25 Mar 2004 10:03:44 -0000 1.25 *************** *** 108,112 **** #include "http_request.h" ! /* This is naughty... */ #define CORE_PRIVATE --- 108,112 ---- #include "http_request.h" ! /* This is naughty */ #define CORE_PRIVATE *************** *** 915,922 **** accept_rec *content_accept, array_header *accept_charsets, ! char *default_charset ) { int offset = 0; ! char *content_charset; char *accept_profile, *content_profile; float charset_q, accept_q, server_q; --- 915,922 ---- accept_rec *content_accept, array_header *accept_charsets, ! const char *default_charset ) { int offset = 0; ! const char *content_charset; char *accept_profile, *content_profile; float charset_q, accept_q, server_q; *************** *** 983,988 **** * "US-ASCII". */ ! content_charset = content_type->charset; ! if( mod_xhtml_strempty( content_charset )) { /* Sigh... RFC 3023 comes into play here. For most content-types * RFC 2616 specifies the default character set should be --- 983,987 ---- * "US-ASCII". */ ! if( mod_xhtml_strempty( content_type->charset )) { /* Sigh... RFC 3023 comes into play here. For most content-types * RFC 2616 specifies the default character set should be *************** *** 993,1003 **** * See also example 8.5 of RFC 3023. */ ! if( default_charset != NULL ) { content_charset = default_charset; ! } else if( mod_xhtml_strnicmp( content_type->name, "text/xml", 8 ) == 0 ) { content_charset = DEFAULT_TEXT_XML_CHARSET; } else { content_charset = DEFAULT_CHARSET_NAME; } } --- 992,1005 ---- * See also example 8.5 of RFC 3023. */ ! if( ! mod_xhtml_strempty( default_charset )) { content_charset = default_charset; ! } else if( mod_xhtml_strnicmp( content_type->name, "text/xml", 8 ) ! == 0 ) { content_charset = DEFAULT_TEXT_XML_CHARSET; } else { content_charset = DEFAULT_CHARSET_NAME; } + } else { + content_charset = content_type->charset; } |