Skip to content

Commit bfed654

Browse files
Wallbrakeraeubanks
authored andcommitted
[LLVM-C] Use NameLen in LLVMGetNamedGlobalAlias
I tried to look over the file and didn't see any other non-use of *Len variables. Reviewed By: deadalnix Differential Revision: https://reviews.llvm.org/D116482
1 parent 1324bb2 commit bfed654

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/lib/IR/Core.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -2293,7 +2293,7 @@ LLVMValueRef LLVMAddAlias2(LLVMModuleRef M, LLVMTypeRef ValueTy,
22932293

22942294
LLVMValueRef LLVMGetNamedGlobalAlias(LLVMModuleRef M,
22952295
const char *Name, size_t NameLen) {
2296-
return wrap(unwrap(M)->getNamedAlias(Name));
2296+
return wrap(unwrap(M)->getNamedAlias(StringRef(Name, NameLen)));
22972297
}
22982298

22992299
LLVMValueRef LLVMGetFirstGlobalAlias(LLVMModuleRef M) {

0 commit comments

Comments
 (0)