summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/activation.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/activation.c b/src/activation.c
index 3018d0a..34ea741 100644
--- a/src/activation.c
+++ b/src/activation.c
@@ -314,11 +314,17 @@ static idevice_activation_error_t idevice_activation_parse_buddyml_response(idev
xmlXPathFreeObject(xpath_result);
xpath_result = NULL;
}
- xpath_result = xmlXPathEvalExpression((const xmlChar*) "/xmlui/page/tableView/section[@footer and not(@footerLinkURL)]/@footer", context);
+ xpath_result = xmlXPathEvalExpression((const xmlChar*) "/xmlui/page/tableView/section/footer[not (@url)]", context);
if (!xpath_result) {
result = IDEVICE_ACTIVATION_E_INTERNAL_ERROR;
goto cleanup;
}
+ if (!xpath_result->nodesetval) {
+ xmlXPathFreeObject(xpath_result);
+ xpath_result = xmlXPathEvalExpression((const xmlChar*) "/xmlui/page/tableView/section[@footer and not(@footerLinkURL)]/@footer", context);
+ result = IDEVICE_ACTIVATION_E_INTERNAL_ERROR;
+ goto cleanup;
+ }
if (xpath_result->nodesetval) {
char* response_description = (char*) malloc(sizeof(char));
@@ -348,6 +354,7 @@ static idevice_activation_error_t idevice_activation_parse_buddyml_response(idev
xmlXPathFreeObject(xpath_result);
xpath_result = NULL;
}
+
xpath_result = xmlXPathEvalExpression((const xmlChar*) "/xmlui/page//editableTextRow", context);
if (!xpath_result) {
result = IDEVICE_ACTIVATION_E_INTERNAL_ERROR;