mirror of
https://github.com/curl/curl.git
synced 2026-08-25 01:33:31 +03:00
lib: save a bit of space with some structure packing
- Reorder some internal struct members so that less padding is used. This is an attempt at saving a bit of space by packing some structs (using pahole to find the holes) where it might make sense to do so without losing readability. I.e., I tried to avoid separating fields that seem grouped together (like the cwd... fields in struct ftp_conn for instance). Also abstained from touching fields behind conditional macros as that quickly can get complicated. Closes https://github.com/curl/curl/pull/6483
This commit is contained in:
parent
46f4736356
commit
0a5827571f
12 changed files with 31 additions and 33 deletions
|
|
@ -200,8 +200,8 @@ struct Curl_sh_entry {
|
|||
struct Curl_hash transfers; /* hash of transfers using this socket */
|
||||
unsigned int action; /* what combined action READ/WRITE this socket waits
|
||||
for */
|
||||
void *socketp; /* settable by users with curl_multi_assign() */
|
||||
unsigned int users; /* number of transfers using this */
|
||||
void *socketp; /* settable by users with curl_multi_assign() */
|
||||
unsigned int readers; /* this many transfers want to read */
|
||||
unsigned int writers; /* this many transfers want to write */
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue