Author: teemperor Date: Wed Sep 4 05:38:43 2019 New Revision: 370887 URL: http://llvm.org/viewvc/llvm-project?rev=370887&view=rev Log: [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. Modified: lldb/trunk/source/Host/common/Socket.cpp Modified: lldb/trunk/source/Host/common/Socket.cpp URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Host/common/Socket.cpp?rev=370887&r1=370886&r2=370887&view=diff ============================================================================== --- lldb/trunk/source/Host/common/Socket.cpp (original) +++ lldb/trunk/source/Host/common/Socket.cpp Wed Sep 4 05:38:43 2019 @@ -353,6 +353,7 @@ Status Socket::Read(void *buf, size_t &n } 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, si ", 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()); } _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits