Add special error text for the -1 launch error code

This commit is contained in:
Cameron Gutman
2020-04-25 16:29:47 -07:00
parent f49a908dc0
commit 2ec6639351

View File

@@ -61,15 +61,20 @@
}
xmlChar* statusMsgXml = xmlGetProp(node, (const xmlChar*)[TAG_STATUS_MESSAGE UTF8String]);
NSString* statusMsg;
if (statusMsgXml != NULL) {
statusMsg = [NSString stringWithUTF8String:(const char*)statusMsgXml];
self.statusMessage = [NSString stringWithUTF8String:(const char*)statusMsgXml];
xmlFree(statusMsgXml);
}
else {
statusMsg = @"Server Error";
self.statusMessage = @"Server Error";
}
if (self.statusCode == -1 && [self.statusMessage isEqualToString:@"Invalid"]) {
// Special case handling an audio capture error which GFE doesn't
// provide any useful status message for.
self.statusCode = 418;
self.statusMessage = @"Missing audio capture device. Reinstalling GeForce Experience should resolve this error.";
}
self.statusMessage = statusMsg;
node = node->children;