Fixed a bug in RFC-2231 implementation.
This commit is contained in:
parent
7b3dd58edb
commit
af45ec7216
@ -6,6 +6,8 @@ VERSION 0.7.1cvs
|
|||||||
|
|
||||||
* Fixed compilation errors with g++ 4.0.
|
* Fixed compilation errors with g++ 4.0.
|
||||||
|
|
||||||
|
* defaultParameter.cpp: fixed a bug in RFC-2231 implementation.
|
||||||
|
|
||||||
2005-06-13 Vincent Richard <vincent@vincent-richard.net>
|
2005-06-13 Vincent Richard <vincent@vincent-richard.net>
|
||||||
|
|
||||||
* word.cpp: fixed a bug in parsing, when the first character of word data
|
* word.cpp: fixed a bug in parsing, when the first character of word data
|
||||||
|
@ -200,7 +200,7 @@ void defaultParameter::generate(utility::outputStream& os, const string::size_ty
|
|||||||
bool needQuoting = false;
|
bool needQuoting = false;
|
||||||
string::size_type valueLength = 0;
|
string::size_type valueLength = 0;
|
||||||
|
|
||||||
for (string::size_type i = 0 ; (i < value.length()) && (pos < maxLineLength - 4) ; ++i, ++valueLength)
|
for (string::size_type i = 0 ; (i < value.length()) && (pos + valueLength < maxLineLength - 4) ; ++i, ++valueLength)
|
||||||
{
|
{
|
||||||
switch (value[i])
|
switch (value[i])
|
||||||
{
|
{
|
||||||
|
@ -221,7 +221,8 @@ namespace
|
|||||||
vmime::word("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ",
|
vmime::word("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ",
|
||||||
vmime::charset("charset"))));
|
vmime::charset("charset"))));
|
||||||
|
|
||||||
assert_eq("4", "F: X; param1=abcdefgh;\r\n "
|
assert_eq("4", "F: X; \r\n "
|
||||||
|
"param1=abcdefghijklm;\r\n "
|
||||||
"param1*0*=charset''abc;\r\n "
|
"param1*0*=charset''abc;\r\n "
|
||||||
"param1*1*=defghijkl;\r\n "
|
"param1*1*=defghijkl;\r\n "
|
||||||
"param1*2*=mnopqrstu;\r\n "
|
"param1*2*=mnopqrstu;\r\n "
|
||||||
|
Loading…
Reference in New Issue
Block a user