PR: 2529
Submitted by: Marcus Meissner <meissner@suse.de> Reviewed by: steve Call ssl_new() to reallocate SSL BIO internals if we want to replace the existing internal SSL structure.
This commit is contained in:
parent
4d43129446
commit
db886c2a2b
@ -348,7 +348,11 @@ static long ssl_ctrl(BIO *b, int cmd, long num, void *ptr)
|
|||||||
break;
|
break;
|
||||||
case BIO_C_SET_SSL:
|
case BIO_C_SET_SSL:
|
||||||
if (ssl != NULL)
|
if (ssl != NULL)
|
||||||
|
{
|
||||||
ssl_free(b);
|
ssl_free(b);
|
||||||
|
if (!ssl_new(b))
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
b->shutdown=(int)num;
|
b->shutdown=(int)num;
|
||||||
ssl=(SSL *)ptr;
|
ssl=(SSL *)ptr;
|
||||||
((BIO_SSL *)b->ptr)->ssl=ssl;
|
((BIO_SSL *)b->ptr)->ssl=ssl;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user