summaryrefslogtreecommitdiffstats
path: root/libavformat/os_support.c
diff options
context:
space:
mode:
authorHendrik Leppkes <h.leppkes@gmail.com>2015-11-02 11:43:50 +0100
committerHendrik Leppkes <h.leppkes@gmail.com>2015-11-02 11:43:50 +0100
commit6b5d6c93dda9be232507a188f83e1f639238e958 (patch)
treec195f1947a258c5cd8c122ff13f057488841d2ac /libavformat/os_support.c
parent9dc9b7e682fc6435ae02fa7713a15c53693262bb (diff)
parent00b62968d079e63bf22028f253ac297292436ebe (diff)
downloadffmpeg-streaming-6b5d6c93dda9be232507a188f83e1f639238e958.zip
ffmpeg-streaming-6b5d6c93dda9be232507a188f83e1f639238e958.tar.gz
Merge commit '00b62968d079e63bf22028f253ac297292436ebe'
* commit '00b62968d079e63bf22028f253ac297292436ebe': os_support: Don't try to return the service name as a string in getnameinfo Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
Diffstat (limited to 'libavformat/os_support.c')
-rw-r--r--libavformat/os_support.c11
1 files changed, 2 insertions, 9 deletions
diff --git a/libavformat/os_support.c b/libavformat/os_support.c
index 7950e44..86d0b8f 100644
--- a/libavformat/os_support.c
+++ b/libavformat/os_support.c
@@ -205,16 +205,9 @@ int ff_getnameinfo(const struct sockaddr *sa, int salen,
}
if (serv && servlen > 0) {
- struct servent *ent = NULL;
-#if HAVE_GETSERVBYPORT
if (!(flags & NI_NUMERICSERV))
- ent = getservbyport(sin->sin_port, flags & NI_DGRAM ? "udp" : "tcp");
-#endif /* HAVE_GETSERVBYPORT */
-
- if (ent)
- snprintf(serv, servlen, "%s", ent->s_name);
- else
- snprintf(serv, servlen, "%d", ntohs(sin->sin_port));
+ return EAI_FAIL;
+ snprintf(serv, servlen, "%d", ntohs(sin->sin_port));
}
return 0;
OpenPOWER on IntegriCloud