ref: 163fe6fe242bc84faae7d92f4d8a4ba486e17b17
parent: 3e4c6382451ffa5a835d7464dfa58464a6e5e9fb
parent: e103ecea7fec1f3b47b1568c8976382df43b0b32
author: ruil2 <ruil2@cisco.com>
date: Wed Nov 2 05:31:02 EDT 2016
Merge pull request #2579 from huili2/ubsan_warning_videotype fix warning of video_bitstream_type in UT
--- a/test/decoder/DecUT_DecExt.cpp
+++ b/test/decoder/DecUT_DecExt.cpp
@@ -87,7 +87,7 @@
m_sDecParam.uiTargetDqLayer = rand() % 100;
m_sDecParam.eEcActiveIdc = (ERROR_CON_IDC) (rand() & 7);
m_sDecParam.sVideoProperty.size = sizeof (SVideoProperty);
- m_sDecParam.sVideoProperty.eVideoBsType = (VIDEO_BITSTREAM_TYPE) (rand() % 3);
+ m_sDecParam.sVideoProperty.eVideoBsType = (VIDEO_BITSTREAM_TYPE) (rand() % 2);
m_pData[0] = m_pData[1] = m_pData[2] = NULL;
m_szBuffer[0] = m_szBuffer[1] = m_szBuffer[2] = 0;
@@ -276,7 +276,7 @@
m_sDecParam.bParseOnly = true;
m_sDecParam.eEcActiveIdc = (ERROR_CON_IDC) iNum;
m_sDecParam.sVideoProperty.size = sizeof (SVideoProperty);
- m_sDecParam.sVideoProperty.eVideoBsType = (VIDEO_BITSTREAM_TYPE) (rand() % 3);
+ m_sDecParam.sVideoProperty.eVideoBsType = (VIDEO_BITSTREAM_TYPE) (rand() % 2);
iRet = m_pDec->Initialize (&m_sDecParam);
ASSERT_EQ (iRet, (int32_t) cmResultSuccess);
@@ -309,7 +309,7 @@
m_sDecParam.bParseOnly = false;
m_sDecParam.eEcActiveIdc = (ERROR_CON_IDC) iNum;
m_sDecParam.sVideoProperty.size = sizeof (SVideoProperty);
- m_sDecParam.sVideoProperty.eVideoBsType = (VIDEO_BITSTREAM_TYPE) (rand() % 3);
+ m_sDecParam.sVideoProperty.eVideoBsType = (VIDEO_BITSTREAM_TYPE) (rand() % 2);
iRet = m_pDec->Initialize (&m_sDecParam);
ASSERT_EQ (iRet, (int32_t) cmResultSuccess);