[FFmpeg-devel] [PATCH 2/4] libavformat/tcp: Added an option to reuse sockets
george at nsup.org
Fri Nov 3 10:48:17 EET 2017
Le tridi 13 brumaire, an CCXXVI, Karthick J a écrit :
> +static TCPSocket *first_socket = NULL;
> + avpriv_lock_avformat();
> + socket->next = first_socket;
> + first_socket = socket;
> + avpriv_unlock_avformat();
I strongly oppose this: we do not want new global state.
Also, I am very doubtful about the feature itself. It is public, and as
such should be usable for many uses, but I do not see it useful for
anything but patches 3 and 4. Furthermore, it is a break of abstraction,
sockets lose their simple and clear API, they are not really closed when
they are closed, etc.
If you are trying to implement keepalive HTTP for HLS, then most of the
code should be in http.c and hls*.c, not tcp.c.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 833 bytes
Desc: Digital signature
More information about the ffmpeg-devel