From 558123e11e024734d2c118d888afd71395eb7bdb Mon Sep 17 00:00:00 2001 From: Thulinma Date: Fri, 15 Nov 2013 15:28:39 +0100 Subject: [PATCH] Fixes to FLV library. --- lib/flv_tag.cpp | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/lib/flv_tag.cpp b/lib/flv_tag.cpp index 49643ba1..231f0ab7 100644 --- a/lib/flv_tag.cpp +++ b/lib/flv_tag.cpp @@ -265,17 +265,12 @@ std::string FLV::Tag::tagType(){ /// Returns the 24-bit offset of this tag. /// Returns 0 if the tag isn't H264 int FLV::Tag::offset(){ - if (data[11] & 0x0F == 7){ - return (((data[13] << 16) + (data[14] << 8) + data[15]) << 8) >> 8; - }else{ - return 0; - } + return (((data[13] << 16) + (data[14] << 8) + data[15]) << 8) >> 8; } //offset getter /// Sets the 24-bit offset of this tag. /// Ignored if the tag isn't H264 void FLV::Tag::offset(int o){ - if (data[11] & 0x0F != 7){return;} data[13] = (o >> 16) & 0xFF; data[14] = (o >> 8) & 0XFF; data[15] = o & 0xFF;