diff options
author | Chris Rankin <rankincj@yahoo.com> | 2011-10-01 21:38:25 +0100 |
---|---|---|
committer | Chris Rankin <rankincj@yahoo.com> | 2011-10-01 21:38:25 +0100 |
commit | 81c4665ec233961b07544445b3e21b99fe11c734 (patch) | |
tree | 32fc75be384c9860f3140510204323a1329f3d5c /src | |
parent | 62a669d9f04e83debe729347617a935707badc7e (diff) | |
download | xine-lib-81c4665ec233961b07544445b3e21b99fe11c734.tar.gz xine-lib-81c4665ec233961b07544445b3e21b99fe11c734.tar.bz2 |
Add CLOEXEC flag to DXR3 plugin's descriptors.
Diffstat (limited to 'src')
-rw-r--r-- | src/dxr3/dxr3_decode_spu.c | 2 | ||||
-rw-r--r-- | src/dxr3/dxr3_decode_video.c | 4 | ||||
-rw-r--r-- | src/dxr3/dxr3_scr.c | 2 | ||||
-rw-r--r-- | src/dxr3/video_out_dxr3.c | 8 |
4 files changed, 8 insertions, 8 deletions
diff --git a/src/dxr3/dxr3_decode_spu.c b/src/dxr3/dxr3_decode_spu.c index 683666d21..8789ffa11 100644 --- a/src/dxr3/dxr3_decode_spu.c +++ b/src/dxr3/dxr3_decode_spu.c @@ -257,7 +257,7 @@ static spu_decoder_t *dxr3_spudec_open_plugin(spu_decoder_class_t *class_gen, xi else { /* open dxr3 spu device */ snprintf(tmpstr, sizeof(tmpstr), "/dev/em8300_sp-%d", this->devnum); - if ((this->fd_spu = open(tmpstr, O_WRONLY)) < 0) { + if ((this->fd_spu = open_cloexec(tmpstr, O_WRONLY)) < 0) { xprintf(this->stream->xine, XINE_VERBOSITY_LOG, _("dxr3_decode_spu: Failed to open spu device %s (%s)\n"), tmpstr, strerror(errno)); pthread_mutex_unlock(&this->dxr3_vo->spu_device_lock); diff --git a/src/dxr3/dxr3_decode_video.c b/src/dxr3/dxr3_decode_video.c index 132998a72..101098af3 100644 --- a/src/dxr3/dxr3_decode_video.c +++ b/src/dxr3/dxr3_decode_video.c @@ -249,7 +249,7 @@ static video_decoder_t *dxr3_open_plugin(video_decoder_class_t *class_gen, xine_ /* open later, because dxr3_video_out might have it open until we request a frame */ this->fd_video = -1; - if ((this->fd_control = open(tmpstr, O_WRONLY)) < 0) { + if ((this->fd_control = open_cloexec(tmpstr, O_WRONLY)) < 0) { xprintf(this->stream->xine, XINE_VERBOSITY_LOG, _("dxr3_decode_video: Failed to open control device %s (%s)\n"), tmpstr, strerror(errno)); free(this); @@ -546,7 +546,7 @@ static void dxr3_decode_data(video_decoder_t *this_gen, buf_element_t *buf) /* open the device for the decoder */ snprintf (tmpstr, sizeof(tmpstr), "/dev/em8300_mv-%d", this->devnum); - if ((this->fd_video = open(tmpstr, O_WRONLY)) < 0) { + if ((this->fd_video = open_cloexec(tmpstr, O_WRONLY)) < 0) { xprintf(this->stream->xine, XINE_VERBOSITY_LOG, _("dxr3_decode_video: Failed to open video device %s (%s)\n"), tmpstr, strerror(errno)); return; diff --git a/src/dxr3/dxr3_scr.c b/src/dxr3/dxr3_scr.c index dd0ea5840..ad6d98b50 100644 --- a/src/dxr3/dxr3_scr.c +++ b/src/dxr3/dxr3_scr.c @@ -75,7 +75,7 @@ dxr3_scr_t *dxr3_scr_init(xine_t *xine) devnum = xine->config->register_num(xine->config, CONF_KEY, 0, CONF_NAME, CONF_HELP, 10, NULL, NULL); snprintf(tmpstr, sizeof(tmpstr), "/dev/em8300-%d", devnum); - if ((this->fd_control = open(tmpstr, O_WRONLY)) < 0) { + if ((this->fd_control = open_cloexec(tmpstr, O_WRONLY)) < 0) { xprintf(this->xine, XINE_VERBOSITY_DEBUG, "dxr3_scr: Failed to open control device %s (%s)\n", tmpstr, strerror(errno)); free(this); diff --git a/src/dxr3/video_out_dxr3.c b/src/dxr3/video_out_dxr3.c index f4121f59c..bc89e901d 100644 --- a/src/dxr3/video_out_dxr3.c +++ b/src/dxr3/video_out_dxr3.c @@ -276,7 +276,7 @@ static vo_driver_t *dxr3_vo_open_plugin(video_driver_class_t *class_gen, const v snprintf(tmpstr, sizeof(tmpstr), "/dev/em8300-%d", class->devnum); llprintf(LOG_VID, "Entering video init, devname = %s.\n", tmpstr); - if ((this->fd_control = open(tmpstr, O_WRONLY)) < 0) { + if ((this->fd_control = open_cloexec(tmpstr, O_WRONLY)) < 0) { xprintf(this->class->xine, XINE_VERBOSITY_LOG, _("video_out_dxr3: Failed to open control device %s (%s)\n"), tmpstr, strerror(errno)); @@ -285,7 +285,7 @@ static vo_driver_t *dxr3_vo_open_plugin(video_driver_class_t *class_gen, const v } snprintf (tmpstr, sizeof(tmpstr), "/dev/em8300_mv-%d", class->devnum); - if ((this->fd_video = open (tmpstr, O_WRONLY | O_SYNC )) < 0) { + if ((this->fd_video = open_cloexec(tmpstr, O_WRONLY | O_SYNC )) < 0) { xprintf(this->class->xine, XINE_VERBOSITY_LOG, _("video_out_dxr3: Failed to open video device %s (%s)\n"), tmpstr, strerror(errno)); return 0; @@ -658,7 +658,7 @@ static void dxr3_update_frame_format(vo_driver_t *this_gen, vo_frame_t *frame_ge /* open the device for the encoder */ snprintf(tmpstr, sizeof(tmpstr), "/dev/em8300_mv-%d", this->class->devnum); - if ((this->fd_video = open(tmpstr, O_WRONLY)) < 0) + if ((this->fd_video = open_cloexec(tmpstr, O_WRONLY)) < 0) xprintf(this->class->xine, XINE_VERBOSITY_DEBUG, "video_out_dxr3: Failed to open video device %s (%s)\n", tmpstr, strerror(errno)); @@ -857,7 +857,7 @@ static void dxr3_overlay_end(vo_driver_t *this_gen, vo_frame_t *frame_gen) /* try to open the dxr3 spu device */ if (!this->fd_spu) { snprintf (tmpstr, sizeof(tmpstr), "/dev/em8300_sp-%d", this->class->devnum); - if ((this->fd_spu = open (tmpstr, O_WRONLY)) < 0) { + if ((this->fd_spu = open_cloexec(tmpstr, O_WRONLY)) < 0) { xprintf(this->class->xine, XINE_VERBOSITY_DEBUG, "video_out_dxr3: Failed to open spu device %s (%s)\n" "video_out_dxr3: Overlays are not available\n", tmpstr, strerror(errno)); |