X-Git-Url: http://git.annexia.org/?a=blobdiff_plain;f=wui_thread.c;h=c51c43f614d0a2ce80b74e75a72bdaa32b43c870;hb=0e605c0d34447f049f14dfd96ace73fb1c0cffaf;hp=0585c898590fbe04384ef059edc427ff9d8e4553;hpb=6ce7a436e33e65a4ddabdbc4d4487cb040f31e87;p=ovirt-viewer.git diff --git a/wui_thread.c b/wui_thread.c index 0585c89..c51c43f 100644 --- a/wui_thread.c +++ b/wui_thread.c @@ -669,6 +669,10 @@ do_login (void) CURL_CHECK_ERROR (curl_easy_setopt, (curl, CURLOPT_FOLLOWLOCATION, (long) 1)); CURL_CHECK_ERROR (curl_easy_setopt, (curl, CURLOPT_MAXREDIRS, (long) 10)); + // FIXME when ssl is introduced into ovirt-viewer, remove there two lines + CURL_CHECK_ERROR(curl_easy_setopt, (curl, CURLOPT_SSL_VERIFYHOST, 0)); + CURL_CHECK_ERROR(curl_easy_setopt, (curl, CURLOPT_SSL_VERIFYPEER, 0)); + /* Try to fetch the URI. */ r = CURL_CHECK_ERROR (curl_easy_perform, (curl)); if (r != CURLE_OK) { @@ -977,6 +981,7 @@ parse_vm_from_xml (xmlNodePtr node) vm.hostid = -1; vm.id = -1; vm.vnc_port = -1; + vm.forward_vnc_port = -1; vm.mem_allocated = -1; vm.mem_used = -1; vm.vcpus_allocated = -1; @@ -1053,6 +1058,13 @@ parse_vm_from_xml (xmlNodePtr node) xmlFree (str); } } + else if (xmlStrcmp (p->name, (const xmlChar *) "forward-vnc-port") == 0) { + str = xmlNodeGetContent (p); + if (str != NULL) { + vm.forward_vnc_port = strtol ((char *) str, NULL, 10); + xmlFree (str); + } + } else if (xmlStrcmp (p->name, (const xmlChar *) "vnic-mac-addr") == 0) { str = xmlNodeGetContent (p); if (str != NULL) { @@ -1072,6 +1084,8 @@ parse_vm_from_xml (xmlNodePtr node) DEBUG ("required field \"description\" missing from structure"); else if (vm.vnc_port == -1) DEBUG ("required field \"vnc-port\" missing from structure"); + else if (vm.forward_vnc_port == -1) + DEBUG ("required field \"forward-vnc-port\" missing from structure"); else if (vm.uuid == NULL) DEBUG ("required field \"uuid\" missing from structure"); else