Mercurial > audlegacy-plugins
comparison src/ffmpeg/libavcodec/parser.c @ 818:07107d476f32 trunk
[svn] - remove some more stuff
- build libavcodec directly into the module
| author | nenolod |
|---|---|
| date | Mon, 12 Mar 2007 13:49:56 -0700 |
| parents | b3b7a4e480b2 |
| children |
comparison
equal
deleted
inserted
replaced
| 817:b3b7a4e480b2 | 818:07107d476f32 |
|---|---|
| 46 if (!s) | 46 if (!s) |
| 47 return NULL; | 47 return NULL; |
| 48 s->parser = parser; | 48 s->parser = parser; |
| 49 s->priv_data = av_mallocz(parser->priv_data_size); | 49 s->priv_data = av_mallocz(parser->priv_data_size); |
| 50 if (!s->priv_data) { | 50 if (!s->priv_data) { |
| 51 free(s); | 51 av_free(s); |
| 52 return NULL; | 52 return NULL; |
| 53 } | 53 } |
| 54 if (parser->parser_init) { | 54 if (parser->parser_init) { |
| 55 ret = parser->parser_init(s); | 55 ret = parser->parser_init(s); |
| 56 if (ret != 0) { | 56 if (ret != 0) { |
| 57 free(s->priv_data); | 57 av_free(s->priv_data); |
| 58 free(s); | 58 av_free(s); |
| 59 return NULL; | 59 return NULL; |
| 60 } | 60 } |
| 61 } | 61 } |
| 62 return s; | 62 return s; |
| 63 } | 63 } |
| 127 void av_parser_close(AVCodecParserContext *s) | 127 void av_parser_close(AVCodecParserContext *s) |
| 128 { | 128 { |
| 129 if (s->parser->parser_close) | 129 if (s->parser->parser_close) |
| 130 s->parser->parser_close(s); | 130 s->parser->parser_close(s); |
| 131 | 131 |
| 132 free(s->priv_data); | 132 av_free(s->priv_data); |
| 133 free(s); | 133 av_free(s); |
| 134 } | 134 } |
| 135 | 135 |
