Skip to content

Commit 9d05a4f

Browse files
committed
Don't orphan ticBuff pointer in wolfSSL_DupSessionEx
1 parent 979b92d commit 9d05a4f

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/ssl.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21455,8 +21455,8 @@ static int wolfSSL_DupSessionEx(const WOLFSSL_SESSION* input,
2145521455
* the static buffer. */
2145621456
if (ticBuff != NULL) {
2145721457
if (ticLenAlloc >= input->ticketLen) {
21458-
output->ticket = output->staticTicket;
21459-
output->ticketLenAlloc = 0;
21458+
output->ticket = ticBuff;
21459+
output->ticketLenAlloc = ticLenAlloc;
2146021460
}
2146121461
else {
2146221462
WOLFSSL_MSG("ticket dynamic buffer too small but we are "

0 commit comments

Comments
 (0)