mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-31 00:30:53 +00:00
fixup a few errors in last mod
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@39301 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
0359dc0a3d
commit
dec747e0b9
1 changed files with 9 additions and 9 deletions
|
@ -2832,7 +2832,7 @@ unfold(const unsigned char *src, const unsigned char *end, BOOL *folded)
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
while (src < end && isWSP(*src))
|
while (src < end && isspace(*src))
|
||||||
{
|
{
|
||||||
if (*src == '\r' || *src == '\n')
|
if (*src == '\r' || *src == '\n')
|
||||||
{
|
{
|
||||||
|
@ -2975,7 +2975,7 @@ unfold(const unsigned char *src, const unsigned char *end, BOOL *folded)
|
||||||
|
|
||||||
src += 2;
|
src += 2;
|
||||||
tmp = src;
|
tmp = src;
|
||||||
while (tmp < end && *tmp != '?' && !isWSP(*tmp))
|
while (tmp < end && *tmp != '?' && !isspace(*tmp))
|
||||||
{
|
{
|
||||||
tmp++;
|
tmp++;
|
||||||
}
|
}
|
||||||
|
@ -2995,12 +2995,12 @@ unfold(const unsigned char *src, const unsigned char *end, BOOL *folded)
|
||||||
|
|
||||||
src = tmp + 1;
|
src = tmp + 1;
|
||||||
if (src >= end) return nil;
|
if (src >= end) return nil;
|
||||||
c = toupper(*src);
|
c = tolower(*src);
|
||||||
if (c == 'B')
|
if (c == 'b')
|
||||||
{
|
{
|
||||||
encoding = WE_BASE64;
|
encoding = WE_BASE64;
|
||||||
}
|
}
|
||||||
else if (c == 'Q')
|
else if (c == 'q')
|
||||||
{
|
{
|
||||||
encoding = WE_QUOTED;
|
encoding = WE_QUOTED;
|
||||||
}
|
}
|
||||||
|
@ -3019,7 +3019,7 @@ unfold(const unsigned char *src, const unsigned char *end, BOOL *folded)
|
||||||
src++;
|
src++;
|
||||||
if (src >= end) return nil;
|
if (src >= end) return nil;
|
||||||
tmp = src;
|
tmp = src;
|
||||||
while (tmp < end && *tmp != '?' && !isWSP(*tmp))
|
while (tmp < end && *tmp != '?' && !isspace(*tmp))
|
||||||
{
|
{
|
||||||
tmp++;
|
tmp++;
|
||||||
}
|
}
|
||||||
|
@ -3138,7 +3138,7 @@ unfold(const unsigned char *src, const unsigned char *end, BOOL *folded)
|
||||||
}
|
}
|
||||||
else if (1 == flags.encodedWord)
|
else if (1 == flags.encodedWord)
|
||||||
{
|
{
|
||||||
if (isWSP(src[0]))
|
if (isspace(src[0]))
|
||||||
{
|
{
|
||||||
expect++; // Count expected space after word
|
expect++; // Count expected space after word
|
||||||
}
|
}
|
||||||
|
@ -3819,7 +3819,7 @@ appendBytes(NSMutableData *m, NSUInteger offset, NSUInteger fold,
|
||||||
/* If we already have space at the end of the line,
|
/* If we already have space at the end of the line,
|
||||||
* we remove it because the wrapping counts as a space.
|
* we remove it because the wrapping counts as a space.
|
||||||
*/
|
*/
|
||||||
if (len > 0 && isWSP(((const uint8_t *)[m bytes])[len - 1]))
|
if (len > 0 && isspace(((const uint8_t *)[m bytes])[len - 1]))
|
||||||
{
|
{
|
||||||
[m setLength: --len];
|
[m setLength: --len];
|
||||||
}
|
}
|
||||||
|
@ -3828,7 +3828,7 @@ appendBytes(NSMutableData *m, NSUInteger offset, NSUInteger fold,
|
||||||
*/
|
*/
|
||||||
[m appendBytes: "\r\n\t" length: 3];
|
[m appendBytes: "\r\n\t" length: 3];
|
||||||
offset = 8;
|
offset = 8;
|
||||||
if (size > 0 && isWSP(bytes[0]))
|
if (size > 0 && isspace(bytes[0]))
|
||||||
{
|
{
|
||||||
/* The folding counts as a space character,
|
/* The folding counts as a space character,
|
||||||
* so we refrain from writing the next character
|
* so we refrain from writing the next character
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue