| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
| 5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
| 6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
| 7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
| 8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
| 9 */ | 9 */ |
| 10 | 10 |
| (...skipping 1043 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1054 packet_.markerBit = false; | 1054 packet_.markerBit = false; |
| 1055 FillPacket(1); | 1055 FillPacket(1); |
| 1056 EXPECT_EQ(packet_buffer_size(), | 1056 EXPECT_EQ(packet_buffer_size(), |
| 1057 static_cast<size_t>(session_.InsertPacket(packet_, frame_buffer_, | 1057 static_cast<size_t>(session_.InsertPacket(packet_, frame_buffer_, |
| 1058 kNoErrors, frame_data))); | 1058 kNoErrors, frame_data))); |
| 1059 | 1059 |
| 1060 EXPECT_EQ(2 * packet_buffer_size(), session_.MakeDecodable()); | 1060 EXPECT_EQ(2 * packet_buffer_size(), session_.MakeDecodable()); |
| 1061 EXPECT_EQ(0U, session_.SessionLength()); | 1061 EXPECT_EQ(0U, session_.SessionLength()); |
| 1062 } | 1062 } |
| 1063 | 1063 |
| 1064 TEST_F(TestNalUnits, SurvivesIncorrectH264StapALength) { |
| 1065 packet_.codecSpecificHeader.codec = kRtpVideoH264; |
| 1066 packet_.codecSpecificHeader.codecHeader.H264.packetization_type = kH264StapA; |
| 1067 const uint8_t kPacket[] = {120, 16, 129, 58}; |
| 1068 packet_.dataPtr = kPacket; |
| 1069 packet_.sizeBytes = sizeof(kPacket); |
| 1070 EXPECT_EQ(kSizeError, session_.InsertPacket(packet_, frame_buffer_, kNoErrors, |
| 1071 frame_data)); |
| 1072 } |
| 1073 |
| 1064 } // namespace webrtc | 1074 } // namespace webrtc |
| OLD | NEW |