diff options
author | David Corrales | 2007-08-05 19:34:20 +0000 |
---|---|---|
committer | David Corrales | 2007-08-05 19:34:20 +0000 |
commit | 6856535010bd2fa4449bcfde1c88dc06cd46e26f (patch) | |
tree | b81a2234c2beff0312c93e039d6cafda4babeca6 /engines/gob/cdrom.cpp | |
parent | 1400d28bfb37fc94f3c44dec0a4d0cef65fb8fb7 (diff) | |
parent | ec1803f838d5efc7decf75c05a1fb4a9633751e5 (diff) | |
download | scummvm-rg350-6856535010bd2fa4449bcfde1c88dc06cd46e26f.tar.gz scummvm-rg350-6856535010bd2fa4449bcfde1c88dc06cd46e26f.tar.bz2 scummvm-rg350-6856535010bd2fa4449bcfde1c88dc06cd46e26f.zip |
Merged fsnode with trunk: r27971:28460
svn-id: r28462
Diffstat (limited to 'engines/gob/cdrom.cpp')
-rw-r--r-- | engines/gob/cdrom.cpp | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/engines/gob/cdrom.cpp b/engines/gob/cdrom.cpp index 6b32720cff..2ee8595ad3 100644 --- a/engines/gob/cdrom.cpp +++ b/engines/gob/cdrom.cpp @@ -68,29 +68,30 @@ void CDROM::readLIC(const char *fname) { _vm->_dataIO->getUnpackedData(tmp); handle = _vm->_dataIO->openData(tmp); + DataStream *stream = _vm->_dataIO->openAsStream(handle, true); - version = _vm->_dataIO->readUint16(handle); - startChunk = _vm->_dataIO->readUint16(handle); - _numTracks = _vm->_dataIO->readUint16(handle); + version = stream->readUint16LE(); + startChunk = stream->readUint16LE(); + _numTracks = stream->readUint16LE(); if (version != 3) error("%s: Unknown version %d", fname, version); - _vm->_dataIO->seekData(handle, 50, SEEK_SET); + stream->seek(50); for (int i = 0; i < startChunk; i++) { - pos = _vm->_dataIO->readUint16(handle); + pos = stream->readUint16LE(); if (!pos) break; - _vm->_dataIO->seekData(handle, pos, SEEK_CUR); + stream->skip(pos); } _LICbuffer = new byte[_numTracks * 22]; - _vm->_dataIO->readData(handle, _LICbuffer, _numTracks * 22); + stream->read(_LICbuffer, _numTracks * 22); - _vm->_dataIO->closeData(handle); + delete stream; } void CDROM::freeLICbuffer() { |