Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(647)

Side by Side Diff: webrtc/modules/video_coding/receiver_unittest.cc

Issue 2685783014: Replace NULL with nullptr in all C++ files. (Closed)
Patch Set: Fixing android. Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. 1 /* Copyright (c) 2013 The WebRTC project authors. All Rights Reserved.
2 * 2 *
3 * Use of this source code is governed by a BSD-style license 3 * Use of this source code is governed by a BSD-style license
4 * that can be found in the LICENSE file in the root of the source 4 * that can be found in the LICENSE file in the root of the source
5 * tree. An additional intellectual property rights grant can be found 5 * tree. An additional intellectual property rights grant can be found
6 * in the file PATENTS. All contributing project authors may 6 * in the file PATENTS. All contributing project authors may
7 * be found in the AUTHORS file in the root of the source tree. 7 * be found in the AUTHORS file in the root of the source tree.
8 */ 8 */
9 9
10 #include <string.h> 10 #include <string.h>
(...skipping 421 matching lines...) Expand 10 before | Expand all | Expand 10 after
432 // build bot to kill the test. 432 // build bot to kill the test.
433 while (num_frames_return < kNumFrames) { 433 while (num_frames_return < kNumFrames) {
434 int64_t start_time = clock_.TimeInMilliseconds(); 434 int64_t start_time = clock_.TimeInMilliseconds();
435 VCMEncodedFrame* frame = receiver_.FrameForDecoding(kMaxWaitTime, false); 435 VCMEncodedFrame* frame = receiver_.FrameForDecoding(kMaxWaitTime, false);
436 int64_t end_time = clock_.TimeInMilliseconds(); 436 int64_t end_time = clock_.TimeInMilliseconds();
437 437
438 // In any case the FrameForDecoding should not wait longer than 438 // In any case the FrameForDecoding should not wait longer than
439 // max_wait_time. 439 // max_wait_time.
440 // In the case that we did not get a frame, it should have been waiting for 440 // In the case that we did not get a frame, it should have been waiting for
441 // exactly max_wait_time. (By the testing samples we constructed above, we 441 // exactly max_wait_time. (By the testing samples we constructed above, we
442 // are sure there is no timing error, so the only case it returns with NULL 442 // are sure there is no timing error, so the only case it returns with null
443 // is that it runs out of time.) 443 // is that it runs out of time.)
444 if (frame) { 444 if (frame) {
445 receiver_.ReleaseFrame(frame); 445 receiver_.ReleaseFrame(frame);
446 ++num_frames_return; 446 ++num_frames_return;
447 EXPECT_GE(kMaxWaitTime, end_time - start_time); 447 EXPECT_GE(kMaxWaitTime, end_time - start_time);
448 } else { 448 } else {
449 EXPECT_EQ(kMaxWaitTime, end_time - start_time); 449 EXPECT_EQ(kMaxWaitTime, end_time - start_time);
450 } 450 }
451 } 451 }
452 } 452 }
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
499 end_time); 499 end_time);
500 receiver_.ReleaseFrame(frame); 500 receiver_.ReleaseFrame(frame);
501 ++num_frames_return; 501 ++num_frames_return;
502 } else { 502 } else {
503 EXPECT_EQ(kMaxWaitTime, end_time - start_time); 503 EXPECT_EQ(kMaxWaitTime, end_time - start_time);
504 } 504 }
505 } 505 }
506 } 506 }
507 507
508 } // namespace webrtc 508 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698