summaryrefslogtreecommitdiff
path: root/libavformat/network.c
Commit message (Collapse)AuthorAge
* network: prevent SIGPIPE on OSXwm42015-05-31
| | | | | | | | OSX does not know MSG_NOSIGNAL. BSD (which OSX is based on) has got the socket option SO_NOSIGPIPE (even if modern BSDs also support MSG_NOSIGNAL). Signed-off-by: Martin Storsjö <martin@martin.st>
* lavf: move TLS-related ifdeffery to library specific fileswm42015-05-26
| | | | | | There is no need to have this mess in network.c. Signed-off-by: Martin Storsjö <martin@martin.st>
* ff_socket: put out-of-line and fallback to fcntl() for close-on-execRémi Denis-Courmont2013-08-09
| | | | | | | This supports non-Linux systems (SOCK_CLOEXEC is non-standard) and older Linux kernels to the extent possible. Signed-off-by: Martin Storsjö <martin@martin.st>
* tcp: Use a different log message and level if there's more addresses to tryMartin Storsjö2013-08-06
| | | | | | | | | This lowers the level of warnings printed if trying to connect to a host name that provides both v6 and v4 addresses but the service only is available on the v4 address (often occurring for 'localhost', with servers that aren't v6-aware). Signed-off-by: Martin Storsjö <martin@martin.st>
* avf: move ff_http_match_no_proxy to networkLuca Barbato2013-06-16
| | | | It is only used by network protocols.
* network: uniform ff_listen_bind and ff_listen_connectLuca Barbato2013-06-04
| | | | | Document the functions and have both use a millisecond timeout and check for interrupt.
* network: factor out connect-listening codeLuca Barbato2013-06-01
| | | | | Introduce ff_listen_connect, to be shared with the other non-tcp network protocols.
* network: factor out bind-listening codeLuca Barbato2013-06-01
| | | | | Introduce ff_listen_bind, to be shared with the other non-tcp network protocols.
* w32pthreads: move from lavc to compat/Anton Khirnov2013-05-24
| | | | It will be used in other places than lavc.
* Remove pointless #undefs of previously forbidden functions.Anton Khirnov2012-12-04
|
* network: use HAVE_THREADS instead of local hackMans Rullgard2012-10-27
| | | | | | | | | HAVE_THREADS is set in config.h if pthreads or w32threads is available, which presumably the proper condition here. Also fixes undefined behaviour in preprocessor directives. Signed-off-by: Mans Rullgard <mans@mansr.com>
* Add some more missing includes after removing the implicit common.hMartin Storsjö2012-08-15
| | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* network: Don't redefine error codes if they already exist in errno.hRonald S. Bultje2012-06-26
| | | | | | | | Since the errno.h values don't match the error codes that winsock returns, map the winsock error codes to the errno ones, to make sure explicit checks against AVERROR(x) match. Signed-off-by: Martin Storsjö <martin@martin.st>
* cosmetics: Remove extra newlines at EOFAlex Converse2012-01-27
|
* network: properly declare WSADATA in windowsSergey Radionov2011-12-21
| | | | | | Fixed "ISO C90 forbids mixed declarations and code" in ff_network_init Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* avformat: Warn about using network functions without calling ↵Martin Storsjö2011-11-07
| | | | | | | | | avformat_network_init This is to make developers aware of the fact that they will start using the new init function at some point. Signed-off-by: Martin Storsjö <martin@martin.st>
* openssl: Only use CRYPTO_set_id_callback on OpenSSL < 1.0.0Martin Storsjö2011-11-06
| | | | | | | | | | | | | Since 1.0.0, this function is deprecated. A new function, CRYPTO_THREADID_set_callback is available, but if not set at all, it uses the address of errno as thread id, which should be sufficient for most systems. On windows, it never was necessary to use this function even before 1.0.0, it used the right win32 API function for this by default. Signed-off-by: Martin Storsjö <martin@martin.st>
* avformat: Initialize gnutls in ff_tls_init()Martin Storsjö2011-11-05
| | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* avformat: Add ff_tls_init()/deinit() that initialize OpenSSLMartin Storsjö2011-11-05
| | | | | | | If the application hasn't set up mutex callbacks, we set up our own using pthreads (or w32pthreads). Signed-off-by: Martin Storsjö <martin@martin.st>
* avformat: Split out functions from network.h to a new file, network.cMartin Storsjö2011-11-05
Signed-off-by: Martin Storsjö <martin@martin.st>