mirror of
https://github.com/curl/curl
synced 2026-08-25 12:32:35 -04:00
Change the storage of easy handle option strings from an array sized for all possible options to a hash set to reduce memory footprint. Give the hash set initially room for 4 strings, with first allocation happening when it goes beyond that. Measurements without test suite and a forced fail on growing the set gives: Size Result 2 1261 tests out of 1951 reported OK: 64% 4 1792 tests out of 1951 reported OK: 91% 8 1944 tests out of 1951 reported OK: 99% 16 1949 tests out of 1951 reported OK: 99% 32 single fail of 3211, unit test for u8_strset Add u8_strset that keeps the tuples (uint8_t id, char *str) and allows set/unset by `id`. Add that as data->set.strings. Define MACROS * CURL_EASY_STR(data, id) for access * CURL_EASY_STR_SET(data, id, s) for setting, making a copy * CURL_EASY_STR_SETN(data, id, s) for setting, no copy * CURL_EASY_STR_CLEAR(data, id) for unsetting * CURL_EASY_STR_CLEAR0(data, id) for unsetting and zero-ing value Add `data->set.str_copypostfields` to handle former `STRING_COPYPOSTFIELDS` string that was not always a string and could carry NUL bytes. Add unit tests to test3211. Closes #22628 |
||
|---|---|---|
| .. | ||
| OS400 | ||
| vms | ||
| Windows | ||
| Makefile.am | ||
| README.md | ||
Packages
This directory and all its subdirectories are for special package information, templates, scripts and docs. The files herein should be of use for those of you who want to package curl in a binary or source format for these platforms.