Skip to content
This repository was archived by the owner on May 21, 2019. It is now read-only.

Commit 40b267e

Browse files
committedDec 19, 2017
Fix a couple of warnings (NFC)
git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@321120 91177308-0d34-0410-b5e6-96231b3b80d8
1 parent 500e8ec commit 40b267e

File tree

4 files changed

+7
-3
lines changed

4 files changed

+7
-3
lines changed
 

‎source/Plugins/Process/MacOSX-Kernel/CommunicationKDP.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ bool CommunicationKDP::SendRequestAndGetReply(
9898
#ifdef LLDB_CONFIGURATION_DEBUG
9999
// NOTE: this only works for packets that are in native endian byte order
100100
assert(request_packet.GetSize() ==
101-
*((uint16_t *)(request_packet.GetData() + 2)));
101+
*((const uint16_t *)(request_packet.GetData() + 2)));
102102
#endif
103103
lldb::offset_t offset = 1;
104104
const uint32_t num_retries = 3;

‎source/Plugins/Process/gdb-remote/GDBRemoteClientBase.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ StateType GDBRemoteClientBase::SendContinuePacketAndWaitForResponse(
6060
continue;
6161
if (steady_clock::now() >= m_interrupt_time + kInterruptTimeout)
6262
return eStateInvalid;
63+
break;
6364
}
6465
case PacketResult::Success:
6566
break;

‎tools/lldb-mi/MICmnLLDBDebuggerHandleEvents.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
#include "lldb/API/SBTarget.h"
1919
#include "lldb/API/SBThread.h"
2020
#include "lldb/API/SBUnixSignals.h"
21+
#include "llvm/Support/Compiler.h"
2122
#ifdef _WIN32
2223
#include <io.h> // For the ::_access()
2324
#else
@@ -899,6 +900,7 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleProcessEventBroadcastBitStateChanged(
899900
bOk = HandleProcessEventStateStopped(vEvent, bShouldBrk);
900901
if (bShouldBrk)
901902
break;
903+
break;
902904
case lldb::eStateCrashed:
903905
case lldb::eStateSuspended:
904906
pEventType = "eStateSuspended";

‎tools/lldb-mi/MIUtilString.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
//===----------------------------------------------------------------------===//
99

1010
// Third party headers
11+
#include "llvm/Support/Compiler.h"
1112
#include <cstdlib>
1213
#include <inttypes.h> // for PRIx8
1314
#include <limits.h> // for ULONG_MAX
@@ -890,7 +891,7 @@ CMIUtilString CMIUtilString::ConvertToPrintableASCII(const char vChar,
890891
case '"':
891892
if (bEscapeQuotes)
892893
return "\\\"";
893-
// fall thru
894+
LLVM_FALLTHROUGH;
894895
default:
895896
if (::isprint(vChar))
896897
return Format("%c", vChar);
@@ -924,7 +925,7 @@ CMIUtilString::ConvertCharValueToPrintableASCII(char vChar,
924925
case '"':
925926
if (bEscapeQuotes)
926927
return "\\\"";
927-
// fall thru
928+
LLVM_FALLTHROUGH;
928929
default:
929930
if (::isprint(vChar))
930931
return Format("%c", vChar);

0 commit comments

Comments
 (0)