~medibuntu-maintainers/mplayer/medibuntu.precise

« back to all changes in this revision

Viewing changes to ffmpeg/tools/pktdumper.c

  • Committer: Package Import Robot
  • Author(s): Reinhard Tartler
  • Date: 2012-01-12 22:23:28 UTC
  • mfrom: (0.4.7 sid)
  • mto: This revision was merged to the branch mainline in revision 76.
  • Revision ID: package-import@ubuntu.com-20120112222328-8jqdyodym3p84ygu
Tags: 2:1.0~rc4.dfsg1+svn34540-1
* New upstream snapshot
* upload to unstable

Show diffs side-by-side

added added

removed removed

Lines of Context:
44
44
{
45
45
    char fntemplate[PATH_MAX];
46
46
    char pktfilename[PATH_MAX];
47
 
    AVFormatContext *fctx;
 
47
    AVFormatContext *fctx = NULL;
48
48
    AVPacket pkt;
49
49
    int64_t pktnum = 0;
50
50
    int64_t maxpkts = 0;
83
83
    // register all file formats
84
84
    av_register_all();
85
85
 
86
 
    err = av_open_input_file(&fctx, argv[1], NULL, 0, NULL);
 
86
    err = avformat_open_input(&fctx, argv[1], NULL, NULL);
87
87
    if (err < 0) {
88
 
        fprintf(stderr, "av_open_input_file: error %d\n", err);
 
88
        fprintf(stderr, "cannot open input: error %d\n", err);
89
89
        return 1;
90
90
    }
91
91
 
92
 
    err = av_find_stream_info(fctx);
 
92
    err = avformat_find_stream_info(fctx, NULL);
93
93
    if (err < 0) {
94
 
        fprintf(stderr, "av_find_stream_info: error %d\n", err);
 
94
        fprintf(stderr, "avformat_find_stream_info: error %d\n", err);
95
95
        return 1;
96
96
    }
97
97
 
117
117
            break;
118
118
    }
119
119
 
120
 
    av_close_input_file(fctx);
 
120
    avformat_close_input(&fctx);
121
121
 
122
122
    while (donotquit)
123
123
        sleep(60);