Diffstat (limited to 'core/multimedia/opieplayer/libmpeg3/mpeg3io.c') (more/less context) (show whitespace changes)
-rw-r--r-- | core/multimedia/opieplayer/libmpeg3/mpeg3io.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/core/multimedia/opieplayer/libmpeg3/mpeg3io.c b/core/multimedia/opieplayer/libmpeg3/mpeg3io.c index c5807a7..c5cae00 100644 --- a/core/multimedia/opieplayer/libmpeg3/mpeg3io.c +++ b/core/multimedia/opieplayer/libmpeg3/mpeg3io.c @@ -31,22 +31,22 @@ int mpeg3_copy_fs(mpeg3_fs_t *dst, mpeg3_fs_t *src) dst->current_byte = 0; return 0; } long mpeg3io_get_total_bytes(mpeg3_fs_t *fs) { -/* - * struct stat st; - * if(stat(fs->path, &st) < 0) return 0; - * return (long)st.st_size; - */ - - fseek(fs->fd, 0, SEEK_END); - fs->total_bytes = ftell(fs->fd); - fseek(fs->fd, 0, SEEK_SET); - return fs->total_bytes; + + struct stat st; + if(stat(fs->path, &st) < 0) return 0; + return (long)st.st_size; + + +/* fseek(fs->fd, 0, SEEK_END); */ +/* fs->total_bytes = ftell(fs->fd); */ +/* fseek(fs->fd, 0, SEEK_SET); */ +/* return fs->total_bytes; */ } int mpeg3io_open_file(mpeg3_fs_t *fs) { /* Need to perform authentication before reading a single byte. */ mpeg3_get_keys(fs->css, fs->path); |