summaryrefslogtreecommitdiff
authorMichael Niedermayer <michaelni@gmx.at>2013-08-08 09:36:21 (GMT)
committer Michael Niedermayer <michaelni@gmx.at>2013-08-08 09:36:21 (GMT)
commit95fa1fe437c7dfe7b9a01685d3e9e9f3525f0bdc (patch)
tree6269787c5022ccabc0f0ccab1289040c51d9bfde
parenteec9c7af3370ee1a114597686382a4ca029392ca (diff)
parent71bf6b41d974229a06921806c333ce98566a5d8a (diff)
downloadffmpeg-95fa1fe437c7dfe7b9a01685d3e9e9f3525f0bdc.zip
ffmpeg-95fa1fe437c7dfe7b9a01685d3e9e9f3525f0bdc.tar.gz
ffmpeg-95fa1fe437c7dfe7b9a01685d3e9e9f3525f0bdc.tar.bz2
Merge commit '71bf6b41d974229a06921806c333ce98566a5d8a'
* commit '71bf6b41d974229a06921806c333ce98566a5d8a': libavdevice: use avpriv_open() Conflicts: libavdevice/v4l2.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat
-rw-r--r--libavdevice/bktr.c3
-rw-r--r--libavdevice/dv1394.c3
-rw-r--r--libavdevice/fbdev.c3
-rw-r--r--libavdevice/oss_audio.c5
4 files changed, 9 insertions, 5 deletions
diff --git a/libavdevice/bktr.c b/libavdevice/bktr.c
index b0dbe60..46d006d 100644
--- a/libavdevice/bktr.c
+++ b/libavdevice/bktr.c
@@ -25,6 +25,7 @@
*/
#include "libavformat/internal.h"
+#include "libavutil/internal.h"
#include "libavutil/log.h"
#include "libavutil/opt.h"
#include "libavutil/parseutils.h"
@@ -135,7 +136,7 @@ static av_cold int bktr_init(const char *video_device, int width, int height,
act.sa_handler = catchsignal;
sigaction(SIGUSR1, &act, &old);
- *tuner_fd = open("/dev/tuner0", O_RDONLY);
+ *tuner_fd = avpriv_open("/dev/tuner0", O_RDONLY);
if (*tuner_fd < 0)
av_log(NULL, AV_LOG_ERROR, "Warning. Tuner not opened, continuing: %s\n", strerror(errno));
diff --git a/libavdevice/dv1394.c b/libavdevice/dv1394.c
index 5d94f5c..0af5ea5 100644
--- a/libavdevice/dv1394.c
+++ b/libavdevice/dv1394.c
@@ -27,6 +27,7 @@
#include <sys/ioctl.h>
#include <sys/mman.h>
+#include "libavutil/internal.h"
#include "libavutil/log.h"
#include "libavutil/opt.h"
#include "avdevice.h"
@@ -88,7 +89,7 @@ static int dv1394_read_header(AVFormatContext * context)
goto failed;
/* Open and initialize DV1394 device */
- dv->fd = open(context->filename, O_RDONLY);
+ dv->fd = avpriv_open(context->filename, O_RDONLY);
if (dv->fd < 0) {
av_log(context, AV_LOG_ERROR, "Failed to open DV interface: %s\n", strerror(errno));
goto failed;
diff --git a/libavdevice/fbdev.c b/libavdevice/fbdev.c
index 74f36d0..1156fb5 100644
--- a/libavdevice/fbdev.c
+++ b/libavdevice/fbdev.c
@@ -34,6 +34,7 @@
#include <time.h>
#include <linux/fb.h>
+#include "libavutil/internal.h"
#include "libavutil/log.h"
#include "libavutil/mem.h"
#include "libavutil/opt.h"
@@ -108,7 +109,7 @@ static av_cold int fbdev_read_header(AVFormatContext *avctx)
if (avctx->flags & AVFMT_FLAG_NONBLOCK)
flags |= O_NONBLOCK;
- if ((fbdev->fd = open(avctx->filename, flags)) == -1) {
+ if ((fbdev->fd = avpriv_open(avctx->filename, flags)) == -1) {
ret = AVERROR(errno);
av_log(avctx, AV_LOG_ERROR,
"Could not open framebuffer device '%s': %s\n",
diff --git a/libavdevice/oss_audio.c b/libavdevice/oss_audio.c
index aa40034..916908c 100644
--- a/libavdevice/oss_audio.c
+++ b/libavdevice/oss_audio.c
@@ -34,6 +34,7 @@
#include <fcntl.h>
#include <sys/ioctl.h>
+#include "libavutil/internal.h"
#include "libavutil/log.h"
#include "libavutil/opt.h"
#include "libavutil/time.h"
@@ -63,9 +64,9 @@ static int audio_open(AVFormatContext *s1, int is_output, const char *audio_devi
char *flip = getenv("AUDIO_FLIP_LEFT");
if (is_output)
- audio_fd = open(audio_device, O_WRONLY);
+ audio_fd = avpriv_open(audio_device, O_WRONLY);
else
- audio_fd = open(audio_device, O_RDONLY);
+ audio_fd = avpriv_open(audio_device, O_RDONLY);
if (audio_fd < 0) {
av_log(s1, AV_LOG_ERROR, "%s: %s\n", audio_device, strerror(errno));
return AVERROR(EIO);