Revision f59d8ff8 libavformat/gxf.c

View differences:

libavformat/gxf.c
397 397
    if (tmp != 1)
398 398
        goto start;
399 399
    last_pos = url_ftell(pb);
400
    if (url_fseek(pb, -5, SEEK_CUR) < 0)
400
    if (avio_seek(pb, -5, SEEK_CUR) < 0)
401 401
        goto out;
402 402
    if (!parse_packet_header(pb, &type, &len) || type != PKT_MEDIA) {
403
        if (url_fseek(pb, last_pos, SEEK_SET) < 0)
403
        if (avio_seek(pb, last_pos, SEEK_SET) < 0)
404 404
            goto out;
405 405
        goto start;
406 406
    }
......
409 409
    cur_timestamp = avio_rb32(pb);
410 410
    last_found_pos = url_ftell(pb) - 16 - 6;
411 411
    if ((track >= 0 && track != cur_track) || (timestamp >= 0 && timestamp > cur_timestamp)) {
412
        if (url_fseek(pb, last_pos, SEEK_SET) >= 0)
412
        if (avio_seek(pb, last_pos, SEEK_SET) >= 0)
413 413
            goto start;
414 414
    }
415 415
out:
416 416
    if (last_found_pos)
417
        url_fseek(pb, last_found_pos, SEEK_SET);
417
        avio_seek(pb, last_found_pos, SEEK_SET);
418 418
    return cur_timestamp;
419 419
}
420 420

  
......
495 495
    if (idx < st->nb_index_entries - 2)
496 496
        maxlen = st->index_entries[idx + 2].pos - pos;
497 497
    maxlen = FFMAX(maxlen, 200 * 1024);
498
    res = url_fseek(s->pb, pos, SEEK_SET);
498
    res = avio_seek(s->pb, pos, SEEK_SET);
499 499
    if (res < 0)
500 500
        return res;
501 501
    found = gxf_resync_media(s, maxlen, -1, timestamp);
......
508 508
                                  int64_t *pos, int64_t pos_limit) {
509 509
    AVIOContext *pb = s->pb;
510 510
    int64_t res;
511
    if (url_fseek(pb, *pos, SEEK_SET) < 0)
511
    if (avio_seek(pb, *pos, SEEK_SET) < 0)
512 512
        return AV_NOPTS_VALUE;
513 513
    res = gxf_resync_media(s, pos_limit - *pos, -1, -1);
514 514
    *pos = url_ftell(pb);

Also available in: Unified diff