diff --git a/ffmpeg_opt.c b/ffmpeg_opt.c
index d2478701d290a906db7e9c4deb11f0e7c144fe80..c5e8e62d7c02d724ab8aa267948a7a3fa84f2f5c 100644
--- a/ffmpeg_opt.c
+++ b/ffmpeg_opt.c
@@ -1978,8 +1978,8 @@ static int opt_data_frames(void *optctx, const char *opt, const char *arg)
 static int opt_default_new(OptionsContext *o, const char *opt, const char *arg)
 {
     int ret;
-    AVCodecContext *cbak = codec_opts;
-    AVCodecContext *fbak = format_opts;
+    AVDictionary *cbak = codec_opts;
+    AVDictionary *fbak = format_opts;
     codec_opts = NULL;
     format_opts = NULL;