summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorLaszlo Papp <lpapp@kde.org>2011-12-06 12:31:05 +0200
committerLaszlo Papp <ext-laszlo.papp@nokia.com>2011-12-06 12:31:05 +0200
commitc460074d90695dcc8b9876bc22b9ec12e1ec199c (patch)
treee1fa52b0117f229b814fa26076bdfd3ace012ad5 /src
parent1ebfb26d73e3fee2d93f34ea1eebd2b92b8a7409 (diff)
Implement the tell operation by using pcm seek and check against the retval
Diffstat (limited to 'src')
-rw-r--r--src/qalvorbisfileaudiodecoder.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/qalvorbisfileaudiodecoder.cpp b/src/qalvorbisfileaudiodecoder.cpp
index 4842f57..ba62147 100644
--- a/src/qalvorbisfileaudiodecoder.cpp
+++ b/src/qalvorbisfileaudiodecoder.cpp
@@ -161,9 +161,9 @@ QALVorbisFileAudioDecoder::pos()
bool
QALVorbisFileAudioDecoder::seek(qint64 pos)
{
- int error;
- if ((error = sf_seek(d->sndFile, pos, SEEK_SET) == -1)) {
- qWarning() << Q_FUNC_INFO << "Failed to seek in the file:" << error;
+ int retval;
+ if ((retval = ov_pcm_seek(d->oggVorbisFile, pos) < 0)) {
+ qWarning() << Q_FUNC_INFO << "Failed to seek in the file:" << retval;
return false;
}