1
0
mirror of git://git.gnupg.org/gnupg.git synced 2024-12-22 10:19:57 +01:00
Justus Winter fc4834d213
dirmngr: Refactor variable-sized array code.
* dirmngr/ks-engine-hkp.c (struct hostinfo_s): Add explicit length and
size fields.
(MAX_POOL_SIZE): New macro.
(create_new_hostinfo): Initialize new fields.
(host_in_pool_p): Adapt.
(select_random_host): Likewise.
(add_host): Likewise.  Move the resizing logic here.
(hostinfo_sort_pool): New function.
(map_host): Simplify.  Move the resizing logic away from here.
(ks_hkp_mark_host): Adapt.
(ks_hkp_print_hosttable): Likewise.
--

The current code assumes that the pool array is only filled when the
hostinfo object is created.  This patch removes that limitation.

GnuPG-bug-id: 3033
Signed-off-by: Justus Winter <justus@g10code.com>
2017-06-20 16:37:11 +02:00
..
2010-12-14 19:17:58 +00:00
2017-02-21 13:11:46 -05:00
2017-02-21 13:11:46 -05:00
2016-09-17 15:57:31 +09:00
2017-04-03 20:56:12 +02:00
2017-03-07 20:25:54 +09:00
2016-12-14 15:56:58 +01:00
2017-03-03 17:17:26 +01:00
2017-03-07 20:25:54 +09:00
2017-03-07 20:25:54 +09:00
2017-03-07 20:25:54 +09:00
2017-03-07 20:25:54 +09:00
2014-03-07 19:00:31 +01:00
2010-06-09 16:53:51 +00:00
2017-03-07 20:25:54 +09:00
2017-03-07 20:25:54 +09:00
2017-03-07 20:25:54 +09:00
2017-04-03 20:56:12 +02:00
2010-06-09 16:53:51 +00:00
2011-02-04 12:57:53 +01:00
2017-03-07 20:25:54 +09:00