[Lldb-commits] [lldb] r251580 - Revert r251578. I was in the middle of editing the commit message

Jason Molenda via lldb-commits lldb-commits at lists.llvm.org
Wed Oct 28 16:31:04 PDT 2015

Author: jmolenda
Date: Wed Oct 28 18:31:03 2015
New Revision: 251580

URL: http://llvm.org/viewvc/llvm-project?rev=251580&view=rev
Revert r251578.  I was in the middle of editing the commit message
and decided to not commit the change, but accidentally committed
it anyway.

This was based on a static analysis complaint; it thought there
was a code path where AdbClient::PushFile would call AdbClient::ReadSyncHeader
and AdbClient::ReadSyncHeader wouldn't set data_len.  But in that
case, the Error object returned will be Fail and we won't use
the data_len or response_id contents.


Modified: lldb/trunk/source/Plugins/Platform/Android/AdbClient.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/Platform/Android/AdbClient.cpp?rev=251580&r1=251579&r2=251580&view=diff
--- lldb/trunk/source/Plugins/Platform/Android/AdbClient.cpp (original)
+++ lldb/trunk/source/Plugins/Platform/Android/AdbClient.cpp Wed Oct 28 18:31:03 2015
@@ -359,7 +359,7 @@ AdbClient::PushFile (const FileSpec &loc
         return error;
     std::string response_id;
-    uint32_t data_len = 0;
+    uint32_t data_len;
     error = ReadSyncHeader (response_id, data_len);
     if (error.Fail ())
         return Error ("Failed to read DONE response: %s", error.AsCString ());

More information about the lldb-commits mailing list