mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-30 08:21:25 +00:00
Fixup for handling cancelled URL loads.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@24819 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
e8f916d126
commit
c6fb5029cf
2 changed files with 17 additions and 1 deletions
|
@ -5407,9 +5407,20 @@ static void indentation(unsigned level, NSMutableString *str)
|
|||
|
||||
- (void) URLHandleResourceDidCancelLoading: (NSURLHandle*)sender
|
||||
{
|
||||
ASSIGN(result, @"timeout");
|
||||
NSString *str;
|
||||
|
||||
[timer invalidate];
|
||||
timer = nil;
|
||||
str = [handle propertyForKeyIfAvailable: NSHTTPPropertyStatusCodeKey];
|
||||
if (str == nil)
|
||||
{
|
||||
str = @"timeout";
|
||||
}
|
||||
else
|
||||
{
|
||||
str = [NSString stringWithFormat: @"HTTP status %@", str];
|
||||
}
|
||||
ASSIGN(result, str);
|
||||
if ([delegate respondsToSelector: @selector(completedXMLRPC:)])
|
||||
{
|
||||
[delegate completedXMLRPC: self];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue