avformat/libsrt: add missing SRT_VERSION_VALUE check

This was missed in d7e2a2bb35.

Signed-off-by: Marton Balint <cus@passwd.hu>
This commit is contained in:
Marton Balint 2020-01-21 23:01:31 +01:00
parent 1001b6a750
commit fee4cafbf5

View File

@ -525,6 +525,7 @@ static int libsrt_open(URLContext *h, const char *uri, int flags)
av_freep(&s->passphrase); av_freep(&s->passphrase);
s->passphrase = av_strndup(buf, strlen(buf)); s->passphrase = av_strndup(buf, strlen(buf));
} }
#if SRT_VERSION_VALUE >= 0x010302
if (av_find_info_tag(buf, sizeof(buf), "enforced_encryption", p)) { if (av_find_info_tag(buf, sizeof(buf), "enforced_encryption", p)) {
s->enforced_encryption = strtol(buf, NULL, 10); s->enforced_encryption = strtol(buf, NULL, 10);
} }
@ -534,6 +535,7 @@ static int libsrt_open(URLContext *h, const char *uri, int flags)
if (av_find_info_tag(buf, sizeof(buf), "kmpreannounce", p)) { if (av_find_info_tag(buf, sizeof(buf), "kmpreannounce", p)) {
s->kmpreannounce = strtol(buf, NULL, 10); s->kmpreannounce = strtol(buf, NULL, 10);
} }
#endif
if (av_find_info_tag(buf, sizeof(buf), "mss", p)) { if (av_find_info_tag(buf, sizeof(buf), "mss", p)) {
s->mss = strtol(buf, NULL, 10); s->mss = strtol(buf, NULL, 10);
} }