1
0
mirror of https://gitlab.com/libvirt/libvirt.git synced 2025-01-09 01:18:00 +03:00

Add SASL to virNetSocket{Local,Remote}AddrString

Rename them to virNetSocket{Local,Remote}AddrStringSASL
to make their format more obvious.
This commit is contained in:
Ján Tomko 2016-06-20 16:01:50 +02:00
parent dbce70b243
commit ea537e7b36
6 changed files with 16 additions and 16 deletions

View File

@ -212,7 +212,7 @@ virNetSocketHasPassFD;
virNetSocketHasPendingData; virNetSocketHasPendingData;
virNetSocketIsLocal; virNetSocketIsLocal;
virNetSocketListen; virNetSocketListen;
virNetSocketLocalAddrString; virNetSocketLocalAddrStringSASL;
virNetSocketNewConnectCommand; virNetSocketNewConnectCommand;
virNetSocketNewConnectExternal; virNetSocketNewConnectExternal;
virNetSocketNewConnectLibSSH2; virNetSocketNewConnectLibSSH2;
@ -227,7 +227,7 @@ virNetSocketNewPostExecRestart;
virNetSocketPreExecRestart; virNetSocketPreExecRestart;
virNetSocketRead; virNetSocketRead;
virNetSocketRecvFD; virNetSocketRecvFD;
virNetSocketRemoteAddrString; virNetSocketRemoteAddrStringSASL;
virNetSocketRemoteAddrStringURI; virNetSocketRemoteAddrStringURI;
virNetSocketRemoveIOCallback; virNetSocketRemoveIOCallback;
virNetSocketSendFD; virNetSocketSendFD;

View File

@ -946,12 +946,12 @@ void virNetClientRemoveStream(virNetClientPtr client,
const char *virNetClientLocalAddrString(virNetClientPtr client) const char *virNetClientLocalAddrString(virNetClientPtr client)
{ {
return virNetSocketLocalAddrString(client->sock); return virNetSocketLocalAddrStringSASL(client->sock);
} }
const char *virNetClientRemoteAddrString(virNetClientPtr client) const char *virNetClientRemoteAddrString(virNetClientPtr client)
{ {
return virNetSocketRemoteAddrString(client->sock); return virNetSocketRemoteAddrStringSASL(client->sock);
} }
#if WITH_GNUTLS #if WITH_GNUTLS

View File

@ -907,7 +907,7 @@ const char *virNetServerClientLocalAddrString(virNetServerClientPtr client)
{ {
if (!client->sock) if (!client->sock)
return NULL; return NULL;
return virNetSocketLocalAddrString(client->sock); return virNetSocketLocalAddrStringSASL(client->sock);
} }
@ -915,7 +915,7 @@ const char *virNetServerClientRemoteAddrString(virNetServerClientPtr client)
{ {
if (!client->sock) if (!client->sock)
return NULL; return NULL;
return virNetSocketRemoteAddrString(client->sock); return virNetSocketRemoteAddrStringSASL(client->sock);
} }
const char *virNetServerClientRemoteAddrStringURI(virNetServerClientPtr client) const char *virNetServerClientRemoteAddrStringURI(virNetServerClientPtr client)

View File

@ -1461,12 +1461,12 @@ int virNetSocketSetBlocking(virNetSocketPtr sock,
} }
const char *virNetSocketLocalAddrString(virNetSocketPtr sock) const char *virNetSocketLocalAddrStringSASL(virNetSocketPtr sock)
{ {
return sock->localAddrStrSASL; return sock->localAddrStrSASL;
} }
const char *virNetSocketRemoteAddrString(virNetSocketPtr sock) const char *virNetSocketRemoteAddrStringSASL(virNetSocketPtr sock)
{ {
return sock->remoteAddrStrSASL; return sock->remoteAddrStrSASL;
} }

View File

@ -148,8 +148,8 @@ void virNetSocketSetSASLSession(virNetSocketPtr sock,
bool virNetSocketHasCachedData(virNetSocketPtr sock); bool virNetSocketHasCachedData(virNetSocketPtr sock);
bool virNetSocketHasPendingData(virNetSocketPtr sock); bool virNetSocketHasPendingData(virNetSocketPtr sock);
const char *virNetSocketLocalAddrString(virNetSocketPtr sock); const char *virNetSocketLocalAddrStringSASL(virNetSocketPtr sock);
const char *virNetSocketRemoteAddrString(virNetSocketPtr sock); const char *virNetSocketRemoteAddrStringSASL(virNetSocketPtr sock);
const char *virNetSocketRemoteAddrStringURI(virNetSocketPtr sock); const char *virNetSocketRemoteAddrStringURI(virNetSocketPtr sock);
int virNetSocketListen(virNetSocketPtr sock, int backlog); int virNetSocketListen(virNetSocketPtr sock, int backlog);

View File

@ -249,12 +249,12 @@ static int testSocketUNIXAddrs(const void *data ATTRIBUTE_UNUSED)
if (virNetSocketNewListenUNIX(path, 0700, -1, getegid(), &lsock) < 0) if (virNetSocketNewListenUNIX(path, 0700, -1, getegid(), &lsock) < 0)
goto cleanup; goto cleanup;
if (STRNEQ(virNetSocketLocalAddrString(lsock), "127.0.0.1;0")) { if (STRNEQ(virNetSocketLocalAddrStringSASL(lsock), "127.0.0.1;0")) {
VIR_DEBUG("Unexpected local address"); VIR_DEBUG("Unexpected local address");
goto cleanup; goto cleanup;
} }
if (virNetSocketRemoteAddrString(lsock) != NULL) { if (virNetSocketRemoteAddrStringSASL(lsock) != NULL) {
VIR_DEBUG("Unexpected remote address"); VIR_DEBUG("Unexpected remote address");
goto cleanup; goto cleanup;
} }
@ -265,12 +265,12 @@ static int testSocketUNIXAddrs(const void *data ATTRIBUTE_UNUSED)
if (virNetSocketNewConnectUNIX(path, false, NULL, &csock) < 0) if (virNetSocketNewConnectUNIX(path, false, NULL, &csock) < 0)
goto cleanup; goto cleanup;
if (STRNEQ(virNetSocketLocalAddrString(csock), "127.0.0.1;0")) { if (STRNEQ(virNetSocketLocalAddrStringSASL(csock), "127.0.0.1;0")) {
VIR_DEBUG("Unexpected local address"); VIR_DEBUG("Unexpected local address");
goto cleanup; goto cleanup;
} }
if (STRNEQ(virNetSocketRemoteAddrString(csock), "127.0.0.1;0")) { if (STRNEQ(virNetSocketRemoteAddrStringSASL(csock), "127.0.0.1;0")) {
VIR_DEBUG("Unexpected remote address"); VIR_DEBUG("Unexpected remote address");
goto cleanup; goto cleanup;
} }
@ -287,12 +287,12 @@ static int testSocketUNIXAddrs(const void *data ATTRIBUTE_UNUSED)
} }
if (STRNEQ(virNetSocketLocalAddrString(ssock), "127.0.0.1;0")) { if (STRNEQ(virNetSocketLocalAddrStringSASL(ssock), "127.0.0.1;0")) {
VIR_DEBUG("Unexpected local address"); VIR_DEBUG("Unexpected local address");
goto cleanup; goto cleanup;
} }
if (STRNEQ(virNetSocketRemoteAddrString(ssock), "127.0.0.1;0")) { if (STRNEQ(virNetSocketRemoteAddrStringSASL(ssock), "127.0.0.1;0")) {
VIR_DEBUG("Unexpected remote address"); VIR_DEBUG("Unexpected remote address");
goto cleanup; goto cleanup;
} }