mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2025-08-01 03:34:39 +02:00
Fix for scan build warning for TLSX_SNI_GetRequest
possible use of null pointer.
This commit is contained in:
@@ -1699,9 +1699,10 @@ word16 TLSX_SNI_GetRequest(TLSX* extensions, byte type, void** data)
|
||||
if (sni && sni->status != WOLFSSL_SNI_NO_MATCH) {
|
||||
switch (sni->type) {
|
||||
case WOLFSSL_SNI_HOST_NAME:
|
||||
if (data)
|
||||
if (data) {
|
||||
*data = sni->data.host_name;
|
||||
return (word16)XSTRLEN((char*)*data);
|
||||
return (word16)XSTRLEN((char*)*data);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user