summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Ryan Prichard <rprichard@google.com> 2024-01-05 18:41:07 -0800
committer Ryan Prichard <rprichard@google.com> 2024-01-05 18:44:27 -0800
commita0cf4ad95a1cc350f2f2c4f0a24cbf2c37c1a4d8 (patch)
tree084d6e87b417952c87b9983c1d9e89775b9b5a1b
parent325c1e106f40c578370d941d206ed9de385dcea0 (diff)
Use operator<< with String16 rather than char16_t*
std::stringstream's operator<< overload for char16_t* is deleted after upgrading libc++ because it surprisingly outputs an address rather than string content. See wg21.link/p1423r3. Bug: 175635923 Test: m MODULES-IN-frameworks-native-cmds-cmd Change-Id: I90602eca166d5da347f7efba22f21bc1a5d38a11
-rw-r--r--cmds/cmd/cmd.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/cmds/cmd/cmd.cpp b/cmds/cmd/cmd.cpp
index 0ce7711574..9695e07753 100644
--- a/cmds/cmd/cmd.cpp
+++ b/cmds/cmd/cmd.cpp
@@ -95,7 +95,7 @@ public:
flags = O_RDWR;
checkRead = checkWrite = true;
} else {
- mErrorLog << "Invalid mode requested: " << mode.c_str() << endl;
+ mErrorLog << "Invalid mode requested: " << mode << endl;
return -EINVAL;
}
int fd = open(fullPath.c_str(), flags, S_IRWXU|S_IRWXG);