diff options
author | miod <> | 2014-04-27 20:26:49 +0000 |
---|---|---|
committer | miod <> | 2014-04-27 20:26:49 +0000 |
commit | 45bb7f0ae87ddf787dd06d515db9afb04a74bf6c (patch) | |
tree | 319f4236c4f33e8d28d3d3a51c99e82d996e948f /src/lib/libcrypto/bio/bss_sock.c | |
parent | cbbb78bcf8e4dca14564fbea5fdfe0703e2951cc (diff) | |
download | openbsd-45bb7f0ae87ddf787dd06d515db9afb04a74bf6c.tar.gz openbsd-45bb7f0ae87ddf787dd06d515db9afb04a74bf6c.tar.bz2 openbsd-45bb7f0ae87ddf787dd06d515db9afb04a74bf6c.zip |
Use C99 initializers for the various FOO_METHOD structs. More readable, and
avoid unreadable/unmaintainable constructs like that:
const EVP_PKEY_ASN1_METHOD cmac_asn1_meth =
{
EVP_PKEY_CMAC,
EVP_PKEY_CMAC,
0,
"CMAC",
"OpenSSL CMAC method",
0,0,0,0,
0,0,0,
cmac_size,
0,
0,0,0,0,0,0,0,
cmac_key_free,
0,
0,0
};
ok matthew@ deraadt@
Diffstat (limited to 'src/lib/libcrypto/bio/bss_sock.c')
-rw-r--r-- | src/lib/libcrypto/bio/bss_sock.c | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/src/lib/libcrypto/bio/bss_sock.c b/src/lib/libcrypto/bio/bss_sock.c index 3dae2562bf..757e1dbb8f 100644 --- a/src/lib/libcrypto/bio/bss_sock.c +++ b/src/lib/libcrypto/bio/bss_sock.c | |||
@@ -74,16 +74,14 @@ static int sock_free(BIO *data); | |||
74 | int BIO_sock_should_retry(int s); | 74 | int BIO_sock_should_retry(int s); |
75 | 75 | ||
76 | static BIO_METHOD methods_sockp = { | 76 | static BIO_METHOD methods_sockp = { |
77 | BIO_TYPE_SOCKET, | 77 | .type = BIO_TYPE_SOCKET, |
78 | "socket", | 78 | .name = "socket", |
79 | sock_write, | 79 | .bwrite = sock_write, |
80 | sock_read, | 80 | .bread = sock_read, |
81 | sock_puts, | 81 | .bputs = sock_puts, |
82 | NULL, /* sock_gets, */ | 82 | .ctrl = sock_ctrl, |
83 | sock_ctrl, | 83 | .create = sock_new, |
84 | sock_new, | 84 | .destroy = sock_free |
85 | sock_free, | ||
86 | NULL, | ||
87 | }; | 85 | }; |
88 | 86 | ||
89 | BIO_METHOD * | 87 | BIO_METHOD * |