[lldb] Fix a warning
authorKazu Hirata <kazu@google.com>
Sat, 15 Oct 2022 19:32:20 +0000 (12:32 -0700)
committerKazu Hirata <kazu@google.com>
Sat, 15 Oct 2022 19:32:20 +0000 (12:32 -0700)
This patch fixes:

  lldb/source/Commands/CommandObjectThread.cpp:66:61: warning:
  comparison of unsigned expression in ‘< 0’ is always false
  [-Wtype-limits]

lldb/source/Commands/CommandObjectThread.cpp

index 7b739fe..2a22900 100644 (file)
@@ -63,7 +63,7 @@ public:
 
       switch (short_option) {
       case 'c':
-        if (option_arg.getAsInteger(0, m_count) || (m_count < 0)) {
+        if (option_arg.getAsInteger(0, m_count)) {
           m_count = UINT32_MAX;
           error.SetErrorStringWithFormat(
               "invalid integer value for option '%c'", short_option);