From f49a908dc06c9ec139cc9ba450c9bc6aeb0c9a0a Mon Sep 17 00:00:00 2001 From: Cameron Gutman Date: Thu, 23 Apr 2020 20:07:52 -0700 Subject: [PATCH] Fix parsing rare GFE status code of 0xFFFFFFFF --- Limelight/Network/AppListResponse.m | 2 +- Limelight/Network/HttpResponse.m | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Limelight/Network/AppListResponse.m b/Limelight/Network/AppListResponse.m index db9c6ba..5edf385 100644 --- a/Limelight/Network/AppListResponse.m +++ b/Limelight/Network/AppListResponse.m @@ -44,7 +44,7 @@ static const char* TAG_APP_INSTALL_PATH = "AppInstallPath"; xmlChar* statusStr = xmlGetProp(node, (const xmlChar*)[TAG_STATUS_CODE UTF8String]); if (statusStr != NULL) { - int status = [[NSString stringWithUTF8String:(const char*)statusStr] intValue]; + int status = (int)[[NSString stringWithUTF8String:(const char*)statusStr] longLongValue]; xmlFree(statusStr); self.statusCode = status; } diff --git a/Limelight/Network/HttpResponse.m b/Limelight/Network/HttpResponse.m index eec7092..b9ddcd5 100644 --- a/Limelight/Network/HttpResponse.m +++ b/Limelight/Network/HttpResponse.m @@ -55,7 +55,7 @@ xmlChar* statusStr = xmlGetProp(node, (const xmlChar*)[TAG_STATUS_CODE UTF8String]); if (statusStr != NULL) { - int status = [[NSString stringWithUTF8String:(const char*)statusStr] intValue]; + int status = (int)[[NSString stringWithUTF8String:(const char*)statusStr] longLongValue]; xmlFree(statusStr); self.statusCode = status; }