mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-07 20:04:03 +00:00
llvm-undname: Fix another crash-on-invalid found by oss-fuzz
llvm-svn: 358363
This commit is contained in:
parent
8335a271a1
commit
67b0012529
@ -654,7 +654,10 @@ Demangler::translateIntrinsicFunctionCode(char CH,
|
||||
IdentifierNode *
|
||||
Demangler::demangleFunctionIdentifierCode(StringView &MangledName,
|
||||
FunctionIdentifierCodeGroup Group) {
|
||||
assert(!MangledName.empty());
|
||||
if (MangledName.empty()) {
|
||||
Error = true;
|
||||
return nullptr;
|
||||
}
|
||||
switch (Group) {
|
||||
case FunctionIdentifierCodeGroup::Basic:
|
||||
switch (char CH = MangledName.popFront()) {
|
||||
|
@ -114,3 +114,8 @@
|
||||
; CHECK-EMPTY:
|
||||
; CHECK-NEXT: ??}
|
||||
; CHECK-NEXT: error: Invalid mangled name
|
||||
|
||||
?foo@?$?_
|
||||
; CHECK-EMPTY:
|
||||
; CHECK-NEXT: ?foo@?$?_
|
||||
; CHECK-NEXT: error: Invalid mangled name
|
||||
|
Loading…
Reference in New Issue
Block a user