mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-11 12:25:53 +00:00
112783 r=ducarroz sr=bienvenu. free charset got from parsing headers before setting to ISO-8859-1
This commit is contained in:
parent
dc8b10ae25
commit
67c66b0acb
@ -1790,8 +1790,10 @@ WriteLineToStream (MimeObject *obj, const char *line, PRBool aDoCharConversion)
|
||||
charset = FindCharacterSet(obj);
|
||||
|
||||
if ( (!charset) || ( (charset) && (!nsCRT::strcasecmp(charset, "us-ascii"))) )
|
||||
{
|
||||
PR_Free(charset);
|
||||
charset = nsCRT::strdup("ISO-8859-1");
|
||||
|
||||
}
|
||||
// convert from the resource charset.
|
||||
res = INTL_ConvertCharset(charset, "UTF-8", line, nsCRT::strlen(line),
|
||||
&converted, &converted_length);
|
||||
|
Loading…
Reference in New Issue
Block a user