mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-24 06:02:27 +00:00
more detailed debug
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@11838 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
7d7324444c
commit
f8945c7da3
2 changed files with 17 additions and 6 deletions
|
@ -308,7 +308,10 @@ static void debugWrite(NSData *data)
|
|||
* Don't start a load if one is in progress.
|
||||
*/
|
||||
if (connectionState != idle)
|
||||
return;
|
||||
{
|
||||
NSLog(@"Attempt to load an http handle which is not idle ... ignored");
|
||||
return;
|
||||
}
|
||||
|
||||
[dat setLength: 0];
|
||||
RELEASE(document);
|
||||
|
@ -316,8 +319,11 @@ static void debugWrite(NSData *data)
|
|||
parser = [GSMimeParser new];
|
||||
document = RETAIN([parser document]);
|
||||
[self beginLoadInBackground];
|
||||
[sock closeFile];
|
||||
DESTROY(sock);
|
||||
if (sock != nil)
|
||||
{
|
||||
[sock closeFile];
|
||||
DESTROY(sock);
|
||||
}
|
||||
contentLength = 0;
|
||||
if ([[request objectForKey: GSHTTPPropertyProxyHostKey] length] == 0)
|
||||
{
|
||||
|
|
|
@ -2077,10 +2077,12 @@ parseCharacterSet(NSString *token)
|
|||
|
||||
- (BOOL) _unfoldHeader
|
||||
{
|
||||
char c = 0;
|
||||
char c;
|
||||
BOOL unwrappingComplete = NO;
|
||||
|
||||
lineStart = lineEnd;
|
||||
NSDebugMLLog(@"GSMime", @"entry: input:%u dataEnd:%u lineStart:%u '%*.*s'",
|
||||
input, dataEnd, lineStart, dataEnd - input, dataEnd - input, &bytes[input]);
|
||||
/*
|
||||
* RFC822 lets header fields break across lines, with continuation
|
||||
* lines beginning with whitespace. This is called folding - and the
|
||||
|
@ -2099,7 +2101,7 @@ parseCharacterSet(NSString *token)
|
|||
}
|
||||
if (pos == dataEnd)
|
||||
{
|
||||
return NO; /* need more data */
|
||||
break; /* need more data */
|
||||
}
|
||||
pos++;
|
||||
if (c == '\r' && pos < dataEnd && bytes[pos] == '\n')
|
||||
|
@ -2108,7 +2110,7 @@ parseCharacterSet(NSString *token)
|
|||
}
|
||||
if (pos == dataEnd)
|
||||
{
|
||||
return NO; /* need more data */
|
||||
break; /* need more data */
|
||||
}
|
||||
/*
|
||||
* Copy data up to end of line, and skip past end.
|
||||
|
@ -2163,6 +2165,9 @@ parseCharacterSet(NSString *token)
|
|||
}
|
||||
}
|
||||
}
|
||||
NSDebugMLLog(@"GSMime", @"exit: inBody:%d unwrappingComplete: %d "
|
||||
@"input:%u dataEnd:%u lineStart:%u '%*.*s'", inBody, unwrappingComplete,
|
||||
input, dataEnd, lineStart, dataEnd - input, dataEnd - input, &bytes[input]);
|
||||
return unwrappingComplete;
|
||||
}
|
||||
@end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue