diff --git a/mindspore-lite/minddata/dataset/kernels/image/dvpp/utils/AclLiteUtils.cc b/mindspore-lite/minddata/dataset/kernels/image/dvpp/utils/AclLiteUtils.cc index 76a0ab8c9bdb74dfe633d2ee1adc19caff2f746e..88be2dae7536fd03541c5cf9018d4840f141f0f8 100644 --- a/mindspore-lite/minddata/dataset/kernels/image/dvpp/utils/AclLiteUtils.cc +++ b/mindspore-lite/minddata/dataset/kernels/image/dvpp/utils/AclLiteUtils.cc @@ -480,7 +480,7 @@ bool AnalyseLine(const std::string &line, std::string &key, std::string &value) } end_pos = pos - 1; } - std::string new_line = line.substr(start_pos, start_pos + 1 - end_pos); // delete comment + std::string new_line = line.substr(start_pos, end_pos - start_pos + 1); // delete comment pos = new_line.find(EQUALS_CHAR); if (pos == std::string::npos) { // has no = return false;