Sometimes captive portal system might return these status codes when continuing with g_web_request_get after the initial 302 status code. Let the browser handle these cases.
000 is seen with http://www.hotspotsystem.com/ 505 is seen with http://nextmesh.net/ Special thanks to Lorn Potter. Signed-off-by: Pasi Sjöholm <pasi.sjoh...@jollamobile.com> --- src/wispr.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/wispr.c b/src/wispr.c index dcce93c..4b60c69 100644 --- a/src/wispr.c +++ b/src/wispr.c @@ -711,6 +711,12 @@ static bool wispr_portal_web_result(GWebResult *result, gpointer user_data) DBG("status: %03u", status); switch (status) { + case 000: + DBG("Status code 000 (proxy?), handling over to the browser"); + __connman_agent_request_browser(wp_context->service, + wispr_portal_browser_reply_cb, + wp_context->status_url, wp_context); + break; case 200: if (wp_context->wispr_msg.message_type >= 0) break; @@ -755,6 +761,12 @@ static bool wispr_portal_web_result(GWebResult *result, gpointer user_data) } break; + case 505: + DBG("HTTP version not supported, hand over to the browser"); + __connman_agent_request_browser(wp_context->service, + wispr_portal_browser_reply_cb, + wp_context->status_url, wp_context); + break; default: break; } -- 1.9.1 _______________________________________________ connman mailing list connman@connman.net https://lists.connman.net/mailman/listinfo/connman