summaryrefslogtreecommitdiff
path: root/src/lib/libssl/ssl_locl.h
diff options
context:
space:
mode:
authorjsing <>2014-05-30 05:27:32 +0000
committerjsing <>2014-05-30 05:27:32 +0000
commit2ff11427d41a52cb126e9892413db066f8ae166a (patch)
tree4f04b783673b0faaaaf6c93f2f8aae36b0a98fad /src/lib/libssl/ssl_locl.h
parent61d7f261556644e324166e1060cf7715a5b63454 (diff)
downloadopenbsd-2ff11427d41a52cb126e9892413db066f8ae166a.tar.gz
openbsd-2ff11427d41a52cb126e9892413db066f8ae166a.tar.bz2
openbsd-2ff11427d41a52cb126e9892413db066f8ae166a.zip
While working on another diff I ended up looking to see why on earth the
DTLS code had a chunk that checked to see if the SSL version was *not* DTLS. Turns out that this is inside a big #if 0 block with a comment explaining why DTLS will never need this code... The DTLS code was clearly written by wholesale copying the SSLv3 code. Any code not applicable to DTLS was seemingly #if 0'd or commented out and left for others to find. d1_pkt.c is copied from s3_pkt.c and it has a do_dtls1_write() function that has the same function signature as do_ssl3_write(), except that the create_empty_fragement (yes, that is the spelling in ssl_locl.h) argument is unused for DTLS (although there is code that pretends to use it) since it uses explicit IV (as the comment notes). Instead of leaving this turd lying around, nuke the #if 0'd code (along with the check for *not* DTLS) and remove the pointless create_empty_fragment argument given the only two do_dtls1_write() calls specify zero. This kind of thing also makes you wonder how much actual peer review occurred before the code was initially committed... ok beck@
Diffstat (limited to 'src/lib/libssl/ssl_locl.h')
-rw-r--r--src/lib/libssl/ssl_locl.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/libssl/ssl_locl.h b/src/lib/libssl/ssl_locl.h
index 16d31f33d2..208610dac1 100644
--- a/src/lib/libssl/ssl_locl.h
+++ b/src/lib/libssl/ssl_locl.h
@@ -806,7 +806,7 @@ int dtls1_shutdown(SSL *s);
806long dtls1_get_message(SSL *s, int st1, int stn, int mt, long max, int *ok); 806long dtls1_get_message(SSL *s, int st1, int stn, int mt, long max, int *ok);
807int dtls1_get_record(SSL *s); 807int dtls1_get_record(SSL *s);
808int do_dtls1_write(SSL *s, int type, const unsigned char *buf, 808int do_dtls1_write(SSL *s, int type, const unsigned char *buf,
809 unsigned int len, int create_empty_fragement); 809 unsigned int len);
810int dtls1_dispatch_alert(SSL *s); 810int dtls1_dispatch_alert(SSL *s);
811int dtls1_enc(SSL *s, int snd); 811int dtls1_enc(SSL *s, int snd);
812 812