mirror of
https://github.com/sparkle-project/Sparkle
synced 2026-11-28 05:14:34 +00:00
Log detailed XML parsing error
This commit is contained in:
1 parent
4e60a61036
commit
b40a4eefde
2 files changed
+11
-2
No files matched your search
Vendored
+5
-1
@@ -229,7 +229,11 @@
|
||||
}
|
||||
|
||||
if (failed) {
|
||||
[self reportError:[NSError errorWithDomain:SUSparkleErrorDomain code:SUAppcastParseError userInfo:@{ NSLocalizedDescriptionKey: SULocalizedString(@"An error occurred while parsing the update feed.", nil) }]];
|
||||
[self reportError:[NSError errorWithDomain:SUSparkleErrorDomain
|
||||
code:SUAppcastParseError
|
||||
userInfo:@{
|
||||
NSLocalizedDescriptionKey: SULocalizedString(@"An error occurred while parsing the update feed.", nil),
|
||||
NSUnderlyingErrorKey: error ? error : [NSNull null]}]];
|
||||
} else {
|
||||
self.completionBlock(nil);
|
||||
self.completionBlock = nil;
|
||||
|
||||
Vendored
+6
-1
@@ -558,7 +558,12 @@
|
||||
- (void)abortUpdateWithError:(NSError *)error
|
||||
{
|
||||
if ([error code] != SUNoUpdateError) { // Let's not bother logging this.
|
||||
SULog(@"Error: %@ %@ (URL %@)", error.localizedDescription, error.localizedFailureReason, error.userInfo[NSURLErrorFailingURLErrorKey]);
|
||||
NSError *errorToDisplay = error;
|
||||
int finiteRecursion=5;
|
||||
do {
|
||||
SULog(@"Error: %@ %@ (URL %@)", errorToDisplay.localizedDescription, errorToDisplay.localizedFailureReason, errorToDisplay.userInfo[NSURLErrorFailingURLErrorKey]);
|
||||
errorToDisplay = errorToDisplay.userInfo[NSUnderlyingErrorKey];
|
||||
} while(--finiteRecursion && errorToDisplay);
|
||||
}
|
||||
if (self.download) {
|
||||
[self.download cancel];
|
||||
|
||||
Reference in new issue
Block a user