[libutils] Modernize codebase by replacing NULL with nullptr
Fixes -Wzero-as-null-pointer-constant warning.
Test: m
Bug: 68236239
Change-Id: I5e89ec8c42151875439d2656475a8739ab9cb7dc
diff --git a/libutils/include/utils/Printer.h b/libutils/include/utils/Printer.h
index a6f6928..7465927 100644
--- a/libutils/include/utils/Printer.h
+++ b/libutils/include/utils/Printer.h
@@ -45,7 +45,7 @@
// (Note that the default ALOG behavior is to ignore blank lines)
LogPrinter(const char* logtag,
android_LogPriority priority = ANDROID_LOG_DEBUG,
- const char* prefix = 0,
+ const char* prefix = nullptr,
bool ignoreBlankLines = false);
// Print the specified line to logcat. No \n at the end is necessary.
@@ -66,7 +66,7 @@
// Create a printer using the specified file descriptor.
// - Each line will be prefixed with 'indent' number of blank spaces.
// - In addition, each line will be prefixed with the 'prefix' string.
- FdPrinter(int fd, unsigned int indent = 0, const char* prefix = 0);
+ FdPrinter(int fd, unsigned int indent = 0, const char* prefix = nullptr);
// Print the specified line to the file descriptor. \n is appended automatically.
virtual void printLine(const char* string);
@@ -90,7 +90,7 @@
// Create a printer using the specified String8 as the target.
// - In addition, each line will be prefixed with the 'prefix' string.
// - target's memory lifetime must be a superset of this String8Printer.
- String8Printer(String8* target, const char* prefix = 0);
+ String8Printer(String8* target, const char* prefix = nullptr);
// Append the specified line to the String8. \n is appended automatically.
virtual void printLine(const char* string);