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

Unified Diff: webrtc/test/rtp_file_writer.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 side-by-side diff with in-line comments
Download patch
Index: webrtc/test/rtp_file_writer.cc
diff --git a/webrtc/test/rtp_file_writer.cc b/webrtc/test/rtp_file_writer.cc
index d9e058646814a0dc80b75b8af0159521f20ab167..59a5a1c060d7fb6b13379f699b794dfc8eeac16b 100644
--- a/webrtc/test/rtp_file_writer.cc
+++ b/webrtc/test/rtp_file_writer.cc
@@ -28,13 +28,13 @@ static const char kFirstLine[] = "#!rtpplay1.0 0.0.0.0/0\n";
class RtpDumpWriter : public RtpFileWriter {
public:
explicit RtpDumpWriter(FILE* file) : file_(file) {
- RTC_CHECK(file_ != NULL);
+ RTC_CHECK(file_ != nullptr);
Init();
}
virtual ~RtpDumpWriter() {
- if (file_ != NULL) {
+ if (file_ != nullptr) {
fclose(file_);
- file_ = NULL;
+ file_ = nullptr;
}
}
@@ -92,16 +92,16 @@ class RtpDumpWriter : public RtpFileWriter {
RtpFileWriter* RtpFileWriter::Create(FileFormat format,
const std::string& filename) {
FILE* file = fopen(filename.c_str(), "wb");
- if (file == NULL) {
+ if (file == nullptr) {
printf("ERROR: Can't open file: %s\n", filename.c_str());
- return NULL;
+ return nullptr;
}
switch (format) {
case kRtpDump:
return new RtpDumpWriter(file);
}
fclose(file);
- return NULL;
+ return nullptr;
}
} // namespace test

Powered by Google App Engine
This is Rietveld 408576698