Skip to content

Commit

Permalink
Fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
jcdr428 committed Aug 10, 2023
1 parent 4ff2ec2 commit 482d8aa
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 14 deletions.
18 changes: 9 additions & 9 deletions tsMuxer/ac3Codec.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,20 +76,20 @@ class AC3Codec
bool m_waitMoreData;
bool m_downconvertToAC3;
bool m_true_hd_mode;
uint8_t m_fscod;
int m_fscod;
int m_frmsizecod;
uint8_t m_bsid;
uint8_t m_bsidBase;
uint8_t m_strmtyp;
uint8_t m_bsmod;
uint8_t m_acmod;
uint8_t m_dsurmod;
uint8_t m_lfeon;
int m_strmtyp;
int m_bsmod;
int m_acmod;
int m_dsurmod;
int m_lfeon;
uint8_t m_halfratecod;
int m_sample_rate;
int32_t m_bit_rate;
uint8_t m_channels;
uint16_t m_frame_size;
int m_bit_rate;
int m_channels;
int m_frame_size;
bool m_mixinfoexists;

MLPCodec mlp;
Expand Down
4 changes: 2 additions & 2 deletions tsMuxer/bitStream.h
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,9 @@ class BitStreamReader : public BitStream
return prevVal + (m_curVal >> m_bitLeft);
}

inline unsigned showBits(unsigned num)
inline int showBits(unsigned num)
{
if (num > INT_BIT || m_totalBits < num)
if (num > INT_BIT - 1 || m_totalBits < num)
THROW_BITSTREAM_ERR;
unsigned prevVal = 0;
unsigned bitLeft = m_bitLeft;
Expand Down
6 changes: 3 additions & 3 deletions tsMuxer/matroskaDemuxer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1148,7 +1148,7 @@ int MatroskaDemuxer::readPacket(AVPacket &avPacket)
memcpy(&avPacket, newPacket, sizeof(AVPacket));
}
else
memset(&avPacket, 0, sizeof(avPacket));
memset(&avPacket, 0, sizeof(AVPacket));
m_lastDeliveryPacket = newPacket;
return 0;
}
Expand Down Expand Up @@ -1398,7 +1398,7 @@ int MatroskaDemuxer::matroska_parse_info()
double num;
if ((res = ebml_read_float(&id, &num)) < 0)
break;
fileDuration = static_cast<uint64_t>(num * time_scale);
fileDuration = static_cast<uint64_t>(num * static_cast<double>(time_scale));
break;
}

Expand All @@ -1407,7 +1407,7 @@ int MatroskaDemuxer::matroska_parse_info()
char *text;
if ((res = ebml_read_utf8(&id, &text)) < 0)
break;
strncpy(m_title, text, sizeof(title) - 1);
strncpy(m_title, text, sizeof(m_title) - 1);
delete[] text;
break;
}
Expand Down

0 comments on commit 482d8aa

Please sign in to comment.