summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen
diff options
context:
space:
mode:
authorDevang Patel <dpatel@apple.com>2010-02-02 03:37:03 +0000
committerDevang Patel <dpatel@apple.com>2010-02-02 03:37:03 +0000
commit6d404adc1be80cf9b7d5cba6bc2afd7ba8762238 (patch)
tree83a44bc4709f6634b20f26d3705383523f56d569 /llvm/lib/CodeGen
parent15217531f7104f335edbdf9bf03bd32a46cd493c (diff)
downloadbcm5719-llvm-6d404adc1be80cf9b7d5cba6bc2afd7ba8762238.tar.gz
bcm5719-llvm-6d404adc1be80cf9b7d5cba6bc2afd7ba8762238.zip
NULL terminate name in pubtypes sections.
llvm-svn: 95062
Diffstat (limited to 'llvm/lib/CodeGen')
-rw-r--r--llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp b/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
index 7615d619aa0..308fc7ad761 100644
--- a/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
+++ b/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
@@ -2800,7 +2800,7 @@ void DwarfDebug::emitDebugPubTypes() {
Asm->EmitInt32(Entity->getOffset()); EOL("DIE offset");
if (Asm->VerboseAsm) Asm->OutStreamer.AddComment("External Name");
- Asm->OutStreamer.EmitBytes(StringRef(Name, strlen(Name)), 0);
+ Asm->OutStreamer.EmitBytes(StringRef(Name, GI->getKeyLength()+1), 0);
}
Asm->EmitInt32(0); EOL("End Mark");
OpenPOWER on IntegriCloud