diff options
author | Chris Lattner <sabre@nondot.org> | 2008-12-09 19:10:54 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2008-12-09 19:10:54 +0000 |
commit | 2e41b0e6e7573f9a56b7d45ebaba9e3239a9da33 (patch) | |
tree | 877db11380c9d3077fb75b734b14e85186876a47 /clang/lib/CodeGen/CodeGenModule.cpp | |
parent | 058522f1da60c36522c47ac6ac0657796310ca11 (diff) | |
download | bcm5719-llvm-2e41b0e6e7573f9a56b7d45ebaba9e3239a9da33.tar.gz bcm5719-llvm-2e41b0e6e7573f9a56b7d45ebaba9e3239a9da33.zip |
Fix a serious null termination bug found by David Chisnall!
llvm-svn: 60778
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
-rw-r--r-- | clang/lib/CodeGen/CodeGenModule.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp index 80ef53f5f9c..c8fa9949165 100644 --- a/clang/lib/CodeGen/CodeGenModule.cpp +++ b/clang/lib/CodeGen/CodeGenModule.cpp @@ -959,7 +959,7 @@ llvm::Constant *CodeGenModule::GetAddrOfConstantString(const std::string &str, /// character. The result has pointer to array type. llvm::Constant *CodeGenModule::GetAddrOfConstantCString(const std::string &str, const char *GlobalName){ - return GetAddrOfConstantString(str + "\0", GlobalName); + return GetAddrOfConstantString(str + '\0', GlobalName); } /// EmitObjCPropertyImplementations - Emit information for synthesized |