diff options
| author | Raphael Isemann <teemperor@gmail.com> | 2019-09-04 12:38:43 +0000 |
|---|---|---|
| committer | Raphael Isemann <teemperor@gmail.com> | 2019-09-04 12:38:43 +0000 |
| commit | f8b476282eb4f430ca2b857a6b13f413953ad895 (patch) | |
| tree | f039c590d84bb4097dd76c26d159ba19d75687a9 | |
| parent | 3747c48d644c7a567bae13a44698c49e03046bdc (diff) | |
| download | bcm5719-llvm-f8b476282eb4f430ca2b857a6b13f413953ad895.tar.gz bcm5719-llvm-f8b476282eb4f430ca2b857a6b13f413953ad895.zip | |
[lldb] Fix log statement in Socket::Write
We change num_bytes in this method, so this doesn't actually
log the parameter that we called the function with. No test
as we don't test logging code.
llvm-svn: 370887
| -rw-r--r-- | lldb/source/Host/common/Socket.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lldb/source/Host/common/Socket.cpp b/lldb/source/Host/common/Socket.cpp index 9ce36d014f6..525727ed945 100644 --- a/lldb/source/Host/common/Socket.cpp +++ b/lldb/source/Host/common/Socket.cpp @@ -353,6 +353,7 @@ Status Socket::Read(void *buf, size_t &num_bytes) { } Status Socket::Write(const void *buf, size_t &num_bytes) { + const size_t src_len = num_bytes; Status error; int bytes_sent = 0; do { @@ -372,7 +373,7 @@ Status Socket::Write(const void *buf, size_t &num_bytes) { ", src = %p, src_len = %" PRIu64 ", flags = 0) => %" PRIi64 " (error = %s)", static_cast<void *>(this), static_cast<uint64_t>(m_socket), buf, - static_cast<uint64_t>(num_bytes), + static_cast<uint64_t>(src_len), static_cast<int64_t>(bytes_sent), error.AsCString()); } |

