From: Marcel Holtmann Date: Fri, 30 Jul 2010 21:27:46 +0000 (-0700) Subject: Fix WPAD issue with empty result list X-Git-Tag: 2.0_alpha~2545 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=bcc00043a6d0d065a46298f858b39397efda52a4;p=framework%2Fconnectivity%2Fconnman.git Fix WPAD issue with empty result list --- diff --git a/src/wpad.c b/src/wpad.c index c76c63b..5f1f1f5 100644 --- a/src/wpad.c +++ b/src/wpad.c @@ -65,6 +65,9 @@ static void wpad_result(GResolvResultStatus status, if (status == G_RESOLV_RESULT_STATUS_SUCCESS) { char *url; + if (results == NULL || g_strv_length(results) == 0) + return; + url = g_strdup_printf("http://%s/wpad.dat", wpad->hostname); __connman_service_set_proxy_autoconfig(wpad->service, url); g_free(url);