Loading system/vendor_libs/test_vendor_lib/types/bluetooth/uuid.cc +9 −4 Original line number Diff line number Diff line Loading @@ -18,7 +18,6 @@ #include "uuid.h" #include <base/strings/stringprintf.h> #include <algorithm> #include <random> Loading Loading @@ -168,8 +167,14 @@ bool Uuid::operator!=(const Uuid& rhs) const { } std::string Uuid::ToString() const { return base::StringPrintf("%02x%02x%02x%02x-%02x%02x-%02x%02x-%02x%02x-%02x%02x%02x%02x%02x%02x", uu[0], uu[1], uu[2], uu[3], uu[4], uu[5], uu[6], uu[7], uu[8], uu[9], uu[10], uu[11], uu[12], uu[13], uu[14], uu[15]); char buffer[37]; snprintf( buffer, sizeof(buffer), "%02x%02x%02x%02x-%02x%02x-%02x%02x-%02x%02x-%02x%02x%02x%02x%02x%02x", uu[0], uu[1], uu[2], uu[3], uu[4], uu[5], uu[6], uu[7], uu[8], uu[9], uu[10], uu[11], uu[12], uu[13], uu[14], uu[15]); return buffer; } } // namespace bluetooth No newline at end of file Loading
system/vendor_libs/test_vendor_lib/types/bluetooth/uuid.cc +9 −4 Original line number Diff line number Diff line Loading @@ -18,7 +18,6 @@ #include "uuid.h" #include <base/strings/stringprintf.h> #include <algorithm> #include <random> Loading Loading @@ -168,8 +167,14 @@ bool Uuid::operator!=(const Uuid& rhs) const { } std::string Uuid::ToString() const { return base::StringPrintf("%02x%02x%02x%02x-%02x%02x-%02x%02x-%02x%02x-%02x%02x%02x%02x%02x%02x", uu[0], uu[1], uu[2], uu[3], uu[4], uu[5], uu[6], uu[7], uu[8], uu[9], uu[10], uu[11], uu[12], uu[13], uu[14], uu[15]); char buffer[37]; snprintf( buffer, sizeof(buffer), "%02x%02x%02x%02x-%02x%02x-%02x%02x-%02x%02x-%02x%02x%02x%02x%02x%02x", uu[0], uu[1], uu[2], uu[3], uu[4], uu[5], uu[6], uu[7], uu[8], uu[9], uu[10], uu[11], uu[12], uu[13], uu[14], uu[15]); return buffer; } } // namespace bluetooth No newline at end of file