diff --git a/cplusplus/level1_single_api/7_dvpp/vdec_sample/src/Vdec.cpp b/cplusplus/level1_single_api/7_dvpp/vdec_sample/src/Vdec.cpp index 3c6326be3b3ab693dee7071a8b4e0b03458698ce..5a447b14d27e4752dfb39082389a03a8d5b975f0 100644 --- a/cplusplus/level1_single_api/7_dvpp/vdec_sample/src/Vdec.cpp +++ b/cplusplus/level1_single_api/7_dvpp/vdec_sample/src/Vdec.cpp @@ -1191,8 +1191,8 @@ int32_t check_option() __FUNCTION__, __LINE__, g_is_write_file); return HI_FAILURE; } - // Check channel number[1, 96] - if ((g_chn_num > 96) || (g_chn_num < 1)) { + // Check channel number > 0 + if (g_chn_num < 1) { printf("[%s][%d] chan num is invalid, chan num = %u \n", __FUNCTION__, __LINE__, g_chn_num); return HI_FAILURE; } @@ -1213,7 +1213,7 @@ int32_t check_option() return HI_FAILURE; } // Check channel start number - if (g_start_chn_num + g_chn_num >= VDEC_MAX_CHN_NUM) { + if (g_start_chn_num + g_chn_num > VDEC_MAX_CHN_NUM) { printf("[%s][%d] start chan num is invalid, start chan num = %u \n", __FUNCTION__, __LINE__, g_start_chn_num); return HI_FAILURE; }