path: root/stream/stream_pvr.c
Commit message (Collapse)AuthorAgeFilesLines
* Use O_CLOEXEC when creating FDswm42013-11-301-1/+3
| | | | | | | | | | | | | | This is needed so that new processes (created with fork+exec) don't inherit open files, which can be important for a number of reasons. Since O_CLOEXEC is relatively new (POSIX.1-2008, before that Linux specific), we #define it to 0 in io.h to prevent compilation errors on older/crappy systems. At least this is the plan. input.c creates a pipe. For that, add a mp_set_cloexec() function (which is based on Weston's code in vo_wayland.c, but more correct). We could use pipe2() instead, but that is Linux specific. Technically, we have a race condition, but it won't matter.
* stream: don't include linux/types.h in some fileswm42013-11-131-1/+0
| | | | | | Apparently this is not portable to FreeBSD. It turns out that we (probably) don't use any symbols defined by this header directly, so the includes are not needed.
* stream: fix url_options field, make protocols field not fixed lengthwm42013-08-261-3/+3
| | | | | | | | | | | | | | | | | | | | The way the url_options field was handled was not entirely sane: it's actually a flexible array member, so it points to garbage for streams which do not initialize this member (it just points to the data right after the struct, which is garbage in theory and practice). This was not actually a problem, since the field is only used if priv_size is set (due to how this stuff is used). But it doesn't allow setting priv_size only, which might be useful in some cases. Also, make the protocols array not a fixed size array. Most stream implementations have only 1 protocol prefix, but stream_lavf.c has over 10 (whitelists ffmpeg protocols). The high size of the fixed size protocol array wastes space, and it is _still_ annoying to add new prefixes to stream_lavf (have to bump the maximum length), so make it arbitrary length. The two changes (plus some more cosmetic changes) arte conflated into one, because it was annoying going over all the stream implementations.
* core: move contents to mpvcore (2/2)Stefano Pigozzi2013-08-061-1/+1
| | | | Followup commit. Fixes all the files references.
* stream: redo URL parsing, replace m_struct usage with m_configwm42013-08-021-3/+1
| | | | | | | | | | | | | Move the URL parsing code from m_option.c to stream.c, and simplify it dramatically. This code originates from times when http code used this, but now it's just relict from other stream implementations reusing this code. Remove the unused bits and simplify the rest. stream_vcd is insane, and the priv struct is different on every platform, so drop the URL parsing. This means you can't specify a track anymore, only the device. (Does anyone use stream_vcd? Not like this couldn't be fixed, but it doesn't seem worth the effort, especially because it'd require potentially touching platform specific code.)
* stream: remove useless author/comment fieldswm42013-07-121-3/+0
| | | | | | | | | These were printed only with -v. Most streams had them set to useless or redundant values, so it's just badly maintained bloat. Since we remove the "author" field too, and since this may have copyright implications, we add the contents of the author fields to the file headers, except if the name is already part of the file header.
* Cleanup some include statementswm42013-07-121-2/+3
* core: change open_stream and demux_open signaturewm42013-07-121-1/+1
| | | | | | | | | | | This removes the dependency on DEMUXER_TYPE_* and the file_format parameter from the stream open functions. Remove some of the playlist handling code. It looks like this was needed only for loading linked mov files with demux_mov (which was removed long ago). Delete a minor bit of dead network-related code from stream.c as well.
* Rename directories, move files (step 2 of 2)wm42012-11-121-1/+1
| | | | | | | | | | | | Finish renaming directories and moving files. Adjust all include statements to make the previous commit compile. The two commits are separate, because git is bad at tracking renames and content changes at the same time. Also take this as an opportunity to remove the separation between "common" and "mplayer" sources in the Makefile. ("common" used to be shared between mplayer and mencoder.)
* stream_pvr: fix buffer overflowmplayer-svn2012-08-031-16/+13
| | | | | | | | | stream_pvr: Use sizeof() to get destination buffer size. The code in lines 382/384 used the wrong constant. Fixes bug #2066. git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2 Author: reimar
* stream_pvr: fix field size / snprintf size mismatchUoti Urpala2012-04-111-1/+1
| | | | | | | struct station_elem_s had a field "name[8]", but the rest of the code used PVR_STATION_NAME_SIZE as field size in snprintf and some other calls accessing the field. Change the field size to PVR_STATION_NAME_SIZE so it matches the accesses.
* stream_pvr: Replace <sys/fcntl.h> include by <fcntl.h>reimar2011-07-061-1/+1
| | | | | | | | Replace sys/fcntl.h include by fcntl.h include used everywhere else. Also fixes compilation with the Android NDK. git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2
* cleanup: don't check for NULL before free()diego2010-11-081-16/+6
| | | | | | patch by Clément Bœsch, ubitux gmail com git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2
* Delete things related to old translation systemUoti Urpala2010-03-101-1/+0
| | | | | Remove the help/ subdirectory, configure code to create toplevel help_mp.h, and all the '#include "help_mp.h"' lines from .c files.
* Remove trailing whitespace from most filesUoti Urpala2009-07-071-85/+85
* Use '#include <poll.h>' instead of '#include <sys/poll.h>'.diego2008-08-141-1/+1
| | | | | | | It is the standard location as defined by the Open Group. git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2
* Use standard license headers with standard formatting.diego2008-05-141-17/+20
| | | | git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2
* Mark all stream_info_t as constreimar2007-12-021-1/+1
| | | | git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2
* cosmetics: typo fix UNSUPORTED --> UNSUPPORTEDdiego2007-08-281-1/+1
| | | | git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2
* Removing global variables from tv://voroshil2007-07-291-33/+33
| | | | | | | | Step 7: replacing old globals with new structure in stream_pvr.c git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2
* Avoid code duplication and ugly config.h hack by using av_strlcat/av_strlcpyreimar2007-07-051-8/+9
| | | | | | | instead of plain strlcat/strlcpy git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2
* give credits to Sven for pvr channel navigationben2007-05-081-0/+1
| | | | git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2
* support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft ↵ben2007-05-081-23/+760
| | | | | | dot com>) git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2
* deprecated comment from the time the pvr code was half V4L2 and half IVTV ↵ben2007-04-301-2/+0
| | | | | | specific git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2
* removed ivtv driver dependancy in favor of native V4L2 MPEG API (requires ↵ben2006-09-271-242/+264
| | | | | | Linux 2.6.18 and above) git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2
* cosmetic renames because pvr support will soon be less ivtv driver dependantben2006-09-251-11/+11
| | | | git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2
* fix build on some old 2.6 kernels, patch by Gernot Hillierben2006-09-011-0/+1
| | | | git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2
* correctly report audio inputben2006-08-031-10/+2
| | | | git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2
* introduce new 'stream' directory for all stream layer related components and ↵ben2006-07-311-0/+1026
split them from libmpdemux git-svn-id: svn:// b3059339-0415-0410-9bf9-f77b7e298cf2