|
a/src/utils/mimeparse.cpp |
|
b/src/utils/mimeparse.cpp |
1 |
#ifndef lint
|
1 |
#ifndef lint
|
2 |
static char rcsid[] = "@(#$Id: mimeparse.cpp,v 1.18 2007-01-18 14:23:42 dockes Exp $ (C) 2004 J.F.Dockes";
|
2 |
static char rcsid[] = "@(#$Id: mimeparse.cpp,v 1.19 2007-10-17 11:40:35 dockes Exp $ (C) 2004 J.F.Dockes";
|
3 |
#endif
|
3 |
#endif
|
4 |
/*
|
4 |
/*
|
5 |
* This program is free software; you can redistribute it and/or modify
|
5 |
* This program is free software; you can redistribute it and/or modify
|
6 |
* it under the terms of the GNU General Public License as published by
|
6 |
* it under the terms of the GNU General Public License as published by
|
7 |
* the Free Software Foundation; either version 2 of the License, or
|
7 |
* the Free Software Foundation; either version 2 of the License, or
|
|
... |
|
... |
219 |
lex.what = Lexical::token;
|
219 |
lex.what = Lexical::token;
|
220 |
lex.value = in.substr(start, end-start);
|
220 |
lex.value = in.substr(start, end-start);
|
221 |
lex.quote = oquot;
|
221 |
lex.quote = oquot;
|
222 |
return ++end;
|
222 |
return ++end;
|
223 |
} else {
|
223 |
} else {
|
224 |
string::size_type end = in.find_first_of(delims + " \t(", start);
|
224 |
string::size_type end = in.find_first_of(delims + "\r\n \t(", start);
|
225 |
lex.what = Lexical::token;
|
225 |
lex.what = Lexical::token;
|
226 |
lex.quote = 0;
|
226 |
lex.quote = 0;
|
227 |
if (end == string::npos) {
|
227 |
if (end == string::npos) {
|
228 |
end = in.size();
|
228 |
end = in.size();
|
229 |
lex.value = in.substr(start);
|
229 |
lex.value = in.substr(start);
|
|
... |
|
... |
828 |
// Mime header value and parameters extraction
|
828 |
// Mime header value and parameters extraction
|
829 |
const char *tr[] = {
|
829 |
const char *tr[] = {
|
830 |
"text/html;charset = UTF-8 ; otherparam=garb; \n"
|
830 |
"text/html;charset = UTF-8 ; otherparam=garb; \n"
|
831 |
"QUOTEDPARAM=\"quoted value\"",
|
831 |
"QUOTEDPARAM=\"quoted value\"",
|
832 |
|
832 |
|
|
|
833 |
"text/plain; charset=ASCII\r\n name=\"809D3016_5691DPS_5.2.LIC\"",
|
|
|
834 |
|
833 |
"application/x-stuff;"
|
835 |
"application/x-stuff;"
|
834 |
"title*0*=us-ascii'en'This%20is%20even%20more%20;"
|
836 |
"title*0*=us-ascii'en'This%20is%20even%20more%20;"
|
835 |
"title*1*=%2A%2A%2Afun%2A%2A%2A%20;"
|
837 |
"title*1*=%2A%2A%2Afun%2A%2A%2A%20;"
|
836 |
"title*2=\"isn't it!\""
|
838 |
"title*2=\"isn't it!\""
|
837 |
};
|
839 |
};
|