1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-07-01 03:22:48 -05:00

Remove a lot of pointless 'struct' keywords.

This is the commit that f3295e0fb _should_ have been. Yesterday I just
added some typedefs so that I didn't have to wear out my fingers
typing 'struct' in new code, but what I ought to have done is to move
all the typedefs into defs.h with the rest, and then go through
cleaning up the legacy 'struct's all through the existing code.

But I was mostly trying to concentrate on getting the test suite
finished, so I just did the minimum. Now it's time to come back and do
it better.
This commit is contained in:
Simon Tatham
2019-01-04 06:51:44 +00:00
parent abebfdf0dd
commit 35690040fd
39 changed files with 452 additions and 449 deletions

View File

@ -289,11 +289,11 @@ static const ssh2_cipheralg *get_ssh2_cipheralg(BinarySource *in)
fatal_error("ssh2_cipheralg '%.*s': not found", PTRLEN_PRINTF(name));
}
static const struct ssh_kex *get_dh_group(BinarySource *in)
static const ssh_kex *get_dh_group(BinarySource *in)
{
static const struct {
const char *key;
const struct ssh_kexes *value;
const ssh_kexes *value;
} algs[] = {
{"group1", &ssh_diffiehellman_group1},
{"group14", &ssh_diffiehellman_group14},
@ -307,11 +307,11 @@ static const struct ssh_kex *get_dh_group(BinarySource *in)
fatal_error("dh_group '%.*s': not found", PTRLEN_PRINTF(name));
}
static const struct ssh_kex *get_ecdh_alg(BinarySource *in)
static const ssh_kex *get_ecdh_alg(BinarySource *in)
{
static const struct {
const char *key;
const struct ssh_kex *value;
const ssh_kex *value;
} algs[] = {
{"curve25519", &ssh_ec_kex_curve25519},
{"nistp256", &ssh_ec_kex_nistp256},
@ -801,8 +801,8 @@ typedef const ssh2_macalg *TD_macalg;
typedef const ssh_keyalg *TD_keyalg;
typedef const ssh1_cipheralg *TD_ssh1_cipheralg;
typedef const ssh2_cipheralg *TD_ssh2_cipheralg;
typedef const struct ssh_kex *TD_dh_group;
typedef const struct ssh_kex *TD_ecdh_alg;
typedef const ssh_kex *TD_dh_group;
typedef const ssh_kex *TD_ecdh_alg;
typedef RsaSsh1Order TD_rsaorder;
#define WRAPPED_NAME_INNER(a, b, ...) b