summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorFrantišek Dvořák <valtri@users.sourceforge.net>2003-11-24 22:52:15 +0000
committerFrantišek Dvořák <valtri@users.sourceforge.net>2003-11-24 22:52:15 +0000
commitd2d5d96c41f21f2eb60b6ca61619b23ad6187780 (patch)
tree2f83abd003d0c530eea0bbb2cdf965ea04bcd28b /src
parentda841dc7965ca990fe92a6c835c292aa5bb2599d (diff)
downloadxine-lib-d2d5d96c41f21f2eb60b6ca61619b23ad6187780.tar.gz
xine-lib-d2d5d96c41f21f2eb60b6ca61619b23ad6187780.tar.bz2
Support for large files created by RIP input plugin. It's used fseeko(). When configure won't find it, it will be used fseek() with 2 GB limit.
CVS patchset: 5778 CVS date: 2003/11/24 22:52:15
Diffstat (limited to 'src')
-rw-r--r--src/xine-engine/input_rip.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/xine-engine/input_rip.c b/src/xine-engine/input_rip.c
index 002e040d3..cefe5e4cb 100644
--- a/src/xine-engine/input_rip.c
+++ b/src/xine-engine/input_rip.c
@@ -29,13 +29,12 @@
* - it's possible speeder saving streams in the xine without playing:
* xine stream_mrl#save:file.raw\;noaudio\;novideo
*
- * $Id: input_rip.c,v 1.16 2003/11/23 23:43:35 valtri Exp $
+ * $Id: input_rip.c,v 1.17 2003/11/24 22:52:15 valtri Exp $
*/
/* TODO:
* - resume feature (via #append)
* - gui activation (after restarting playback)
- * - long files support
*/
#ifdef HAVE_CONFIG_H
@@ -58,6 +57,10 @@
#include "xine_internal.h"
+#ifndef HAVE_FSEEKO
+# define fseeko fseek
+#endif
+
#define SCRATCH_SIZE 1024
#define MAX_TARGET_LEN 256
#define SEEK_TIMEOUT 2.5
@@ -354,7 +357,7 @@ static off_t rip_plugin_seek(input_plugin_t *this_gen, off_t offset, int origin)
if (this->regular) {
if (reqpos != this->savepos) {
lprintf(" => seeking file to %lld\n", reqpos);
- if (fseek(this->file, reqpos, SEEK_SET) != 0) {
+ if (fseeko(this->file, reqpos, SEEK_SET) != 0) {
xine_log(this->stream->xine, XINE_LOG_MSG,
_("input_rip: seeking failed: %s\n"), strerror(errno));
return -1;
@@ -373,7 +376,7 @@ static off_t rip_plugin_seek(input_plugin_t *this_gen, off_t offset, int origin)
lprintf(" => seeking to end: %lld\n", this->savepos);
if (this->regular) {
lprintf(" => seeking file to end: %lld\n", this->savepos);
- if (fseek(this->file, this->savepos, SEEK_SET) != 0) {
+ if (fseeko(this->file, this->savepos, SEEK_SET) != 0) {
xine_log(this->stream->xine, XINE_LOG_MSG,
_("input_rip: seeking failed: %s\n"), strerror(errno));
return -1;