llist: replace Curl_llist_alloc with Curl_llist_init

No longer allocate the curl_llist head struct for lists separately.

Removes 17 (15%) tiny allocations in a normal "curl localhost" invoke.

closes #1381
This commit is contained in:
Daniel Stenberg 2017-04-03 10:32:43 +02:00
parent a68ca63d73
commit e60fe20fdf
18 changed files with 214 additions and 310 deletions

View file

@ -1356,13 +1356,12 @@ CURLcode Curl_pretransfer(struct Curl_easy *data)
if(data->set.wildcardmatch) {
struct WildcardData *wc = &data->wildcard;
if(!wc->filelist) {
if(wc->state < CURLWC_INIT) {
result = Curl_wildcard_init(wc); /* init wildcard structures */
if(result)
return CURLE_OUT_OF_MEMORY;
}
}
}
return result;