diff options
author | jkeil <jkeil@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2001-07-13 08:44:51 +0000 |
---|---|---|
committer | jkeil <jkeil@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2001-07-13 08:44:51 +0000 |
commit | c6dd2c4deae052a5c074e0dc7f7c1f01b14bb5a2 (patch) | |
tree | 22005ac6460587a95ff707d4c17c2941898d1c03 /vcd_read_fbsd.h | |
parent | 0f2ba866cdd1f7be2de5bac9dffb761de7bd2ad0 (diff) | |
download | mpv-c6dd2c4deae052a5c074e0dc7f7c1f01b14bb5a2.tar.bz2 mpv-c6dd2c4deae052a5c074e0dc7f7c1f01b14bb5a2.tar.xz |
Minor code cleanup from Vladimir Kushnir
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@1312 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'vcd_read_fbsd.h')
-rw-r--r-- | vcd_read_fbsd.h | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/vcd_read_fbsd.h b/vcd_read_fbsd.h index af8db2f50d..f21fb10b48 100644 --- a/vcd_read_fbsd.h +++ b/vcd_read_fbsd.h @@ -12,6 +12,7 @@ typedef struct { uint8_t spare [4]; } cdsector_t; +static cdsector_t vcd_buf; static struct ioc_read_toc_single_entry vcd_entry; static inline void vcd_set_msf(unsigned int sect){ @@ -77,13 +78,10 @@ void vcd_read_toc(int fd){ } } -static cdsector_t vcd_buf; - static int vcd_read(int fd,char *mem){ - off_t offset = 0; + if (pread(fd,&vcd_buf,VCD_SECTOR_SIZE,vcd_get_msf()*VCD_SECTOR_SIZE) != VCD_SECTOR_SIZE) return 0; // EOF? - offset++; vcd_entry.entry.addr.msf.frame++; if (vcd_entry.entry.addr.msf.frame==75){ |