fix
authorAndreas Monzner <andreas.monzner@multimedia-labs.de>
Sun, 25 Jun 2006 22:46:44 +0000 (22:46 +0000)
committerAndreas Monzner <andreas.monzner@multimedia-labs.de>
Sun, 25 Jun 2006 22:46:44 +0000 (22:46 +0000)
lib/dvb/decoder.cpp

index 8e172c8b874ab5c2b78853a148b8dd00ff82fe56..a6b0ccb2d6d75d997baf2e08a9513c9e24e596da 100644 (file)
@@ -782,7 +782,8 @@ RESULT eTSMPEGDecoder::showSinglePic(const char *filename)
                        int vfd = open("/dev/dvb/adapter0/video0", O_RDWR);
                        if (vfd > 0)
                        {
-                               int length = fseek(f, 0, SEEK_END);
+                               fseek(f, 0, SEEK_END);
+                               int length = ftell(f);
                                unsigned char *buffer = new unsigned char[length*3+9];
                                if (ioctl(vfd, VIDEO_FAST_FORWARD, 1) < 0)
                                        eDebug("VIDEO_FAST_FORWARD failed (%m)");