Mercurial > libavcodec.hg
comparison parser.c @ 6891:d7051562c2b3 libavcodec
allow av_parser_close(NULL)
fixes issue300
author | michael |
---|---|
date | Mon, 26 May 2008 01:58:47 +0000 |
parents | 23b2a64342f2 |
children | ef70c05f77e8 |
comparison
equal
deleted
inserted
replaced
6890:5ddf098691d3 | 6891:d7051562c2b3 |
---|---|
212 return 0; | 212 return 0; |
213 } | 213 } |
214 | 214 |
215 void av_parser_close(AVCodecParserContext *s) | 215 void av_parser_close(AVCodecParserContext *s) |
216 { | 216 { |
217 if(s){ | |
217 if (s->parser->parser_close) | 218 if (s->parser->parser_close) |
218 s->parser->parser_close(s); | 219 s->parser->parser_close(s); |
219 av_free(s->priv_data); | 220 av_free(s->priv_data); |
220 av_free(s); | 221 av_free(s); |
222 } | |
221 } | 223 } |
222 | 224 |
223 /*****************************************************/ | 225 /*****************************************************/ |
224 | 226 |
225 /** | 227 /** |