From cfca06d7963fa0909f90483b42a6d7d194d01e08 Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Sun, 26 Jul 2020 19:36:28 +0000 Subject: Vendor import of llvm-project master 2e10b7a39b9, the last commit before the llvmorg-12-init tag, from which release/11.x was branched. --- lldb/source/Target/UnixSignals.cpp | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'lldb/source/Target/UnixSignals.cpp') diff --git a/lldb/source/Target/UnixSignals.cpp b/lldb/source/Target/UnixSignals.cpp index 33090a72df54..dce32adbf0a3 100644 --- a/lldb/source/Target/UnixSignals.cpp +++ b/lldb/source/Target/UnixSignals.cpp @@ -1,4 +1,4 @@ -//===-- UnixSignals.cpp -----------------------------------------*- C++ -*-===// +//===-- UnixSignals.cpp ---------------------------------------------------===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. @@ -145,10 +145,8 @@ bool UnixSignals::SignalIsValid(int32_t signo) const { } ConstString UnixSignals::GetShortName(ConstString name) const { - if (name) { - const char *signame = name.AsCString(); - return ConstString(signame + 3); // Remove "SIG" from name - } + if (name) + return ConstString(name.GetStringRef().substr(3)); // Remove "SIG" from name return name; } -- cgit v1.2.3