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

Side by Side Diff: webrtc/tools/psnr_ssim_analyzer/psnr_ssim_analyzer.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 /* 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 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 parser.SetFlag("results_file", "results.txt"); 112 parser.SetFlag("results_file", "results.txt");
113 parser.SetFlag("help", "false"); 113 parser.SetFlag("help", "false");
114 114
115 parser.ProcessFlags(); 115 parser.ProcessFlags();
116 if (parser.GetFlag("help") == "true") { 116 if (parser.GetFlag("help") == "true") {
117 parser.PrintUsageMessage(); 117 parser.PrintUsageMessage();
118 exit(EXIT_SUCCESS); 118 exit(EXIT_SUCCESS);
119 } 119 }
120 parser.PrintEnteredFlags(); 120 parser.PrintEnteredFlags();
121 121
122 int width = strtol((parser.GetFlag("width")).c_str(), NULL, 10); 122 int width = strtol((parser.GetFlag("width")).c_str(), nullptr, 10);
123 int height = strtol((parser.GetFlag("height")).c_str(), NULL, 10); 123 int height = strtol((parser.GetFlag("height")).c_str(), nullptr, 10);
124 124
125 if (width <= 0 || height <= 0) { 125 if (width <= 0 || height <= 0) {
126 fprintf(stderr, "Error: width or height cannot be <= 0!\n"); 126 fprintf(stderr, "Error: width or height cannot be <= 0!\n");
127 return -1; 127 return -1;
128 } 128 }
129 129
130 CompareFiles(parser.GetFlag("reference_file").c_str(), 130 CompareFiles(parser.GetFlag("reference_file").c_str(),
131 parser.GetFlag("test_file").c_str(), 131 parser.GetFlag("test_file").c_str(),
132 parser.GetFlag("results_file").c_str(), width, height); 132 parser.GetFlag("results_file").c_str(), width, height);
133 } 133 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698