aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat
diff options
context:
space:
mode:
authorPaul B Mahol <onemda@gmail.com>2017-01-16 10:03:54 +0100
committerPaul B Mahol <onemda@gmail.com>2017-01-16 10:24:01 +0100
commite0665d385ee010866cbd93b4da1d040b5b7498b1 (patch)
tree6da2a626eb094b1ecf7e8c8fd0cbea293ca56550 /libavformat
parent40cf943714007d32308e445a9dc43894f6c9479f (diff)
downloadffmpeg-e0665d385ee010866cbd93b4da1d040b5b7498b1.tar.gz
avformat/aadec: stop ignoring file metadata
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/aadec.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/libavformat/aadec.c b/libavformat/aadec.c
index 0f4ec2019d..fa4e6627c8 100644
--- a/libavformat/aadec.c
+++ b/libavformat/aadec.c
@@ -25,6 +25,7 @@
#include "avformat.h"
#include "internal.h"
+#include "libavutil/dict.h"
#include "libavutil/intreadwrite.h"
#include "libavutil/tea.h"
#include "libavutil/opt.h"
@@ -114,12 +115,10 @@ static int aa_read_header(AVFormatContext *s)
if (!strcmp(key, "codec")) {
av_log(s, AV_LOG_DEBUG, "Codec is <%s>\n", val);
strncpy(codec_name, val, sizeof(codec_name) - 1);
- }
- if (!strcmp(key, "HeaderSeed")) {
+ } else if (!strcmp(key, "HeaderSeed")) {
av_log(s, AV_LOG_DEBUG, "HeaderSeed is <%s>\n", val);
header_seed = atoi(val);
- }
- if (!strcmp(key, "HeaderKey")) { // this looks like "1234567890 1234567890 1234567890 1234567890"
+ } else if (!strcmp(key, "HeaderKey")) { // this looks like "1234567890 1234567890 1234567890 1234567890"
av_log(s, AV_LOG_DEBUG, "HeaderKey is <%s>\n", val);
sscanf(val, "%u%u%u%u", &header_key_part[0], &header_key_part[1], &header_key_part[2], &header_key_part[3]);
for (idx = 0; idx < 4; idx++) {
@@ -129,6 +128,8 @@ static int aa_read_header(AVFormatContext *s)
for (i = 0; i < 16; i++)
av_log(s, AV_LOG_DEBUG, "%02x", header_key[i]);
av_log(s, AV_LOG_DEBUG, "\n");
+ } else {
+ av_dict_set(&s->metadata, key, val, 0);
}
}