summaryrefslogtreecommitdiff
path: root/libavcodec/ffv1.c
diff options
context:
space:
mode:
authorAlex Beregszaszi <alex@rtfs.hu>2004-09-10 15:38:14 +0000
committerAlex Beregszaszi <alex@rtfs.hu>2004-09-10 15:38:14 +0000
commitd58a6d8537a6f34941973c5c3be93d484a4d62ed (patch)
tree705cc099bdd1a0be9bdf0be676fcf87d34bea451 /libavcodec/ffv1.c
parent7be8716a2a6c7203989776221f0c77f7253668c0 (diff)
put the warning to the right place to avoid crashes
Originally committed as revision 3448 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/ffv1.c')
-rw-r--r--libavcodec/ffv1.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/libavcodec/ffv1.c b/libavcodec/ffv1.c
index ac8069f577..70ca84fd18 100644
--- a/libavcodec/ffv1.c
+++ b/libavcodec/ffv1.c
@@ -537,6 +537,12 @@ static int encode_init(AVCodecContext *avctx)
FFV1Context *s = avctx->priv_data;
int i;
+ if(avctx->strict_std_compliance >= 0){
+ av_log(avctx, AV_LOG_ERROR, "this codec is under development, files encoded with it wont be decodeable with future versions!!!\n"
+ "use vstrict=-1 to use it anyway\n");
+ return -1;
+ }
+
common_init(avctx);
s->version=0;
@@ -629,12 +635,6 @@ static int encode_frame(AVCodecContext *avctx, unsigned char *buf, int buf_size,
AVFrame * const p= &f->picture;
int used_count= 0;
- if(avctx->strict_std_compliance >= 0){
- av_log(avctx, AV_LOG_ERROR, "this codec is under development, files encoded with it wont be decodeable with future versions!!!\n"
- "use vstrict=-1 to use it anyway\n");
- return -1;
- }
-
ff_init_cabac_encoder(c, buf, buf_size);
ff_init_cabac_states(c, ff_h264_lps_range, ff_h264_mps_state, ff_h264_lps_state, 64);
c->lps_state[2] = 1;