Showing the changes to test/BaseDecoderTest.cpp (1 of 4 files). Show all
Unified · Split
| @@ -16,7 +16,7 @@ static void ReadFrame(std::ifstream* file, BufferedData* buf) { · 15 unmodified lines | ||
| 16 | 16 | if (file->gcount() != 1) { // end of file |
| 17 | 17 | return; |
| 18 | 18 | } |
| 19 | − if (!buf->Push(b)) { | |
| 19 | + if (!buf->PushBack(b)) { | |
| 20 | 20 | FAIL() << "unable to allocate memory"; |
| 21 | 21 | } |
| 22 | 22 | |
| @@ -76,7 +76,7 @@ void BaseDecoderTest::DecodeFrame(const uint8_t* src, int sliceSize, Callback* c · 53 unmodified lines | ||
| 76 | 76 | memset(data, 0, sizeof(data)); |
| 77 | 77 | memset(&bufInfo, 0, sizeof(SBufferInfo)); |
| 78 | 78 | |
| 79 | − DECODING_STATE rv = decoder_->DecodeFrame(src, sliceSize, data, &bufInfo); | |
| 79 | + DECODING_STATE rv = decoder_->DecodeFrame2(src, sliceSize, data, &bufInfo); | |
| 80 | 80 | ASSERT_TRUE(rv == dsErrorFree); |
| 81 | 81 | |
| 82 | 82 | if (bufInfo.iBufferStatus == 1 && cbk != NULL) { |
| @@ -107,7 +107,8 @@ void BaseDecoderTest::DecodeFile(const char* fileName, Callback* cbk) { · 24 unmodified lines | ||
| 107 | 107 | std::ifstream file(fileName, std::ios::in | std::ios::binary); |
| 108 | 108 | ASSERT_TRUE(file.is_open()); |
| 109 | 109 | |
| 110 | − for (BufferedData buf;;) { | |
| 110 | + BufferedData buf; | |
| 111 | + while (true) { | |
| 111 | 112 | ReadFrame(&file, &buf); |
| 112 | 113 | if (::testing::Test::HasFatalFailure()) { |
| 113 | 114 | return; |