mirror of
https://github.com/RPCSX/llvm.git
synced 2024-12-13 23:18:51 +00:00
67635a7f8d
If a filename is a multiple of 18 characters, there will be no null-terminator. This will result in an invalid access by the constructed StringRef. Add a test case to exercise this and fix that handling. Address this same vulnerability in llvm-readobj as well. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@206145 91177308-0d34-0410-b5e6-96231b3b80d8
21 lines
469 B
Plaintext
21 lines
469 B
Plaintext
RUN: yaml2obj %p/Inputs/file-aux-record.yaml | llvm-readobj -t - | FileCheck %s
|
|
|
|
CHECK: Symbols [
|
|
CHECK: Symbol {
|
|
CHECK: Name: .file
|
|
CHECK: Value: 0
|
|
CHECK: StorageClass: File
|
|
CHECK: AuxSymbolCount: 1
|
|
CHECK: AuxFileRecord {
|
|
CHECK: FileName: eighteen-chars.obj{{$}}
|
|
CHECK: }
|
|
CHECK: }
|
|
CHECK: Symbol {
|
|
CHECK: Name: @comp.id
|
|
CHECK: Value: 13485607
|
|
CHECK: StorageClass: Static
|
|
CHECK: AuxSymbolCount: 0
|
|
CHECK: }
|
|
CHECK: ]
|
|
|