diff -Naur grip-3.2.0/src/discdb.c grip-3.2.0-patched/src/discdb.c --- grip-3.2.0/src/discdb.c 2004-04-15 12:23:37.000000000 -0600 +++ grip-3.2.0-patched/src/discdb.c 2004-11-09 15:22:15.000000000 -0700 @@ -187,17 +187,14 @@ g_string_sprintf(proxy,"%s:%d",server->proxy->name, server->proxy->port); - curl_easy_setopt(curl_handle,CURLOPT_PROXY,proxy); - - g_string_free(proxy,TRUE); + curl_easy_setopt(curl_handle,CURLOPT_PROXY,proxy->str); if(*server->proxy->username) { + user=g_string_new(NULL); g_string_sprintf(user,"%s:%s",server->proxy->username, server->proxy->pswd); - curl_easy_setopt(curl_handle,CURLOPT_PROXYUSERPWD,user); - - g_string_free(user,TRUE); + curl_easy_setopt(curl_handle,CURLOPT_PROXYUSERPWD,user->str); } } @@ -238,11 +235,17 @@ fclose(outfile); } - g_string_free(uri,TRUE); - curl_slist_free_all(headers); curl_easy_cleanup(curl_handle); + + g_string_free(uri,TRUE); + if(server->use_proxy) { + g_string_free(proxy,TRUE); + if(*server->proxy->username) { + g_string_free(user,TRUE); + } + } } curl_global_cleanup();