diff options
author | Stefan Huehner <stefan@huehner.org> | 2006-06-18 11:33:14 +0000 |
---|---|---|
committer | Diego Biurrun <diego@biurrun.de> | 2006-06-18 11:33:14 +0000 |
commit | 7b49ce2e344a5f8864d8365d57f3c6c743f0c8f7 (patch) | |
tree | 12c908af01e95ca2df7f4ca20be592871527577e /libavformat/udp.c | |
parent | 3b9bee88891d1c170eb42d1ef51c5cd7f19b5ba5 (diff) | |
download | ffmpeg-streaming-7b49ce2e344a5f8864d8365d57f3c6c743f0c8f7.zip ffmpeg-streaming-7b49ce2e344a5f8864d8365d57f3c6c743f0c8f7.tar.gz |
Add const to (mostly) char* and make some functions static, which aren't used
outside their declaring source file and which have no corresponding prototype.
patch by Stefan Huehner stefan^^@^^huehner^^.^^org
Originally committed as revision 5497 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/udp.c')
-rw-r--r-- | libavformat/udp.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/libavformat/udp.c b/libavformat/udp.c index ee4f67d..fb72096 100644 --- a/libavformat/udp.c +++ b/libavformat/udp.c @@ -51,7 +51,7 @@ typedef struct { #ifdef CONFIG_IPV6 -int udp_ipv6_is_multicast_address(const struct sockaddr *addr) { +static int udp_ipv6_is_multicast_address(const struct sockaddr *addr) { if (addr->sa_family == AF_INET) return IN_MULTICAST(ntohl(((struct sockaddr_in *)addr)->sin_addr.s_addr)); if (addr->sa_family == AF_INET6) @@ -59,7 +59,7 @@ int udp_ipv6_is_multicast_address(const struct sockaddr *addr) { return -1; } -int udp_ipv6_set_multicast_ttl(int sockfd, int mcastTTL, struct sockaddr *addr) { +static int udp_ipv6_set_multicast_ttl(int sockfd, int mcastTTL, struct sockaddr *addr) { if (addr->sa_family == AF_INET) { if (setsockopt(sockfd, IPPROTO_IP, IP_MULTICAST_TTL, &mcastTTL, sizeof(mcastTTL)) < 0) { perror("setsockopt(IP_MULTICAST_TTL)"); @@ -75,7 +75,7 @@ int udp_ipv6_set_multicast_ttl(int sockfd, int mcastTTL, struct sockaddr *addr) return 0; } -int udp_ipv6_join_multicast_group(int sockfd, struct sockaddr *addr) { +static int udp_ipv6_join_multicast_group(int sockfd, struct sockaddr *addr) { struct ip_mreq mreq; struct ipv6_mreq mreq6; if (addr->sa_family == AF_INET) { @@ -97,7 +97,7 @@ int udp_ipv6_join_multicast_group(int sockfd, struct sockaddr *addr) { return 0; } -int udp_ipv6_leave_multicast_group(int sockfd, struct sockaddr *addr) { +static int udp_ipv6_leave_multicast_group(int sockfd, struct sockaddr *addr) { struct ip_mreq mreq; struct ipv6_mreq mreq6; if (addr->sa_family == AF_INET) { @@ -119,7 +119,7 @@ int udp_ipv6_leave_multicast_group(int sockfd, struct sockaddr *addr) { return 0; } -struct addrinfo* udp_ipv6_resolve_host(const char *hostname, int port, int type, int family, int flags) { +static struct addrinfo* udp_ipv6_resolve_host(const char *hostname, int port, int type, int family, int flags) { struct addrinfo hints, *res = 0; int error; char sport[16]; @@ -144,7 +144,7 @@ struct addrinfo* udp_ipv6_resolve_host(const char *hostname, int port, int type, return res; } -int udp_ipv6_set_remote_url(URLContext *h, const char *uri) { +static int udp_ipv6_set_remote_url(URLContext *h, const char *uri) { UDPContext *s = h->priv_data; char hostname[256]; int port; @@ -158,7 +158,7 @@ int udp_ipv6_set_remote_url(URLContext *h, const char *uri) { return 0; } -int udp_ipv6_set_local(URLContext *h) { +static int udp_ipv6_set_local(URLContext *h) { UDPContext *s = h->priv_data; int udp_fd = -1; struct sockaddr_storage clientaddr; |