mirror of
https://github.com/owntone/owntone-server.git
synced 2024-12-28 08:05:56 -05:00
[rtsp] Initialize addr to avoid scan-build issue "Assigned value is
garbage or undefined"
This commit is contained in:
parent
f3a495cd37
commit
75432ce73f
@ -1319,6 +1319,7 @@ evrtsp_connection_get_local_address(struct evrtsp_connection *evcon,
|
|||||||
|
|
||||||
*address = NULL;
|
*address = NULL;
|
||||||
*port = 0;
|
*port = 0;
|
||||||
|
memset(&addr, 0, sizeof(addr));
|
||||||
|
|
||||||
if (!evrtsp_connected(evcon))
|
if (!evrtsp_connected(evcon))
|
||||||
return;
|
return;
|
||||||
@ -1333,7 +1334,7 @@ evrtsp_connection_get_local_address(struct evrtsp_connection *evcon,
|
|||||||
if (!*address)
|
if (!*address)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
*family = addr.ss.ss_family;
|
*family = addr.sa.sa_family;
|
||||||
|
|
||||||
switch (*family)
|
switch (*family)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user