Revision a2704c97 libavformat/mpeg.c

View differences:

libavformat/mpeg.c
169 169
    int max_size, start_code;
170 170

  
171 171
    max_size = *size_ptr;
172
    pos_start = url_ftell(pb);
172
    pos_start = avio_tell(pb);
173 173

  
174 174
    /* in order to go faster, we fill the buffer */
175 175
    pos = pos_start - 16386;
......
241 241
    int len, size, startcode, c, flags, header_len;
242 242
    int pes_ext, ext2_len, id_ext, skip;
243 243
    int64_t pts, dts;
244
    int64_t last_sync= url_ftell(s->pb);
244
    int64_t last_sync= avio_tell(s->pb);
245 245

  
246 246
 error_redo:
247 247
        avio_seek(s->pb, last_sync, SEEK_SET);
......
250 250
        m->header_state = 0xff;
251 251
        size = MAX_SYNC_SIZE;
252 252
        startcode = find_next_start_code(s->pb, &size, &m->header_state);
253
        last_sync = url_ftell(s->pb);
254
    //printf("startcode=%x pos=0x%"PRIx64"\n", startcode, url_ftell(s->pb));
253
        last_sync = avio_tell(s->pb);
254
    //printf("startcode=%x pos=0x%"PRIx64"\n", startcode, avio_tell(s->pb));
255 255
    if (startcode < 0){
256 256
        if(url_feof(s->pb))
257 257
            return AVERROR_EOF;
......
295 295
          (startcode == 0x1bd) || (startcode == 0x1fd)))
296 296
        goto redo;
297 297
    if (ppos) {
298
        *ppos = url_ftell(s->pb) - 4;
298
        *ppos = avio_tell(s->pb) - 4;
299 299
    }
300 300
    len = avio_rb16(s->pb);
301 301
    pts =

Also available in: Unified diff