Address WPACKET review comments
A few style tweaks here and there. The main change is that curr and
packet_len are now offsets into the buffer to account for the fact that
the pointers can change if the buffer grows. Also dropped support for the
WPACKET_set_packet_len() function. I thought that was going to be needed
but so far it hasn't been. It doesn't really work any more due to the
offsets change.
Reviewed-by: Rich Salz <rsalz@openssl.org>
diff --git a/ssl/s3_lib.c b/ssl/s3_lib.c
index 1f9f6af..3749b2c 100644
--- a/ssl/s3_lib.c
+++ b/ssl/s3_lib.c
@@ -2799,7 +2799,7 @@
{
/* Set the content type and 3 bytes for the message len */
if (!WPACKET_put_bytes(pkt, htype, 1)
- || !WPACKET_start_sub_packet_len(pkt, 3))
+ || !WPACKET_start_sub_packet_u24(pkt))
return 0;
return 1;