X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=qt-faststart.c;h=f9de435146baecc0b3140206717c2af466f3fef7;hb=51ebd13654aa40d1f1c3c976842b855be10dd3ac;hp=2cc68631520de679b6c20d8a4b20a43f0b34d4f9;hpb=a8fcaf4019ccb7b5ca5e88f2544afab69c0a3e87;p=ffmpeg diff --git a/qt-faststart.c b/qt-faststart.c index 2cc68631520..f9de435146b 100644 --- a/qt-faststart.c +++ b/qt-faststart.c @@ -243,8 +243,11 @@ int main(int argc, char *argv[]) free(moov_atom); return 1; } - /* seek after ftyp atom if needed */ - fseeko(infile, start_offset, SEEK_SET); + + if (start_offset > 0) { /* seek after ftyp atom */ + fseeko(infile, start_offset, SEEK_SET); + last_offset -= start_offset; + } outfile = fopen(argv[2], "wb"); if (!outfile) {