1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-07-11 16:23:55 -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

@ -159,7 +159,7 @@ static const LogPolicyVtable server_logpolicy_vt = {
LogPolicy server_logpolicy[1] = {{ &server_logpolicy_vt }};
struct AuthPolicy_ssh1_pubkey {
struct RSAKey key;
RSAKey key;
struct AuthPolicy_ssh1_pubkey *next;
};
struct AuthPolicy_ssh2_pubkey {
@ -221,7 +221,7 @@ bool auth_publickey(AuthPolicy *ap, ptrlen username, ptrlen public_blob)
}
return false;
}
struct RSAKey *auth_publickey_ssh1(
RSAKey *auth_publickey_ssh1(
AuthPolicy *ap, ptrlen username, mp_int *rsa_modulus)
{
struct AuthPolicy_ssh1_pubkey *iter;
@ -365,7 +365,7 @@ int main(int argc, char **argv)
ssh_key **hostkeys = NULL;
int nhostkeys = 0, hostkeysize = 0;
struct RSAKey *hostkey1 = NULL;
RSAKey *hostkey1 = NULL;
AuthPolicy ap;
@ -407,7 +407,7 @@ int main(int argc, char **argv)
keytype = key_type(keyfile);
if (keytype == SSH_KEYTYPE_SSH2) {
struct ssh2_userkey *uk;
ssh2_userkey *uk;
ssh_key *key;
uk = ssh2_load_userkey(keyfile, NULL, &error);
filename_free(keyfile);
@ -439,7 +439,7 @@ int main(int argc, char **argv)
"SSH-1 host key\n", appname, val);
exit(1);
}
hostkey1 = snew(struct RSAKey);
hostkey1 = snew(RSAKey);
if (!rsa_ssh1_loadkey(keyfile, hostkey1, NULL, &error)) {
fprintf(stderr, "%s: unable to load host key '%s': "
"%s\n", appname, val, error);