[llvm-commits] CVS: llvm/tools/llvm-prof/llvm-prof.cpp

Reid Spencer reid at x10sys.com
Mon May 7 11:50:24 PDT 2007



Changes in directory llvm/tools/llvm-prof:

llvm-prof.cpp updated: 1.34 -> 1.35
---
Log message:

Initialize variable to null so it has a value in the off chance that a
memory buffer couldn't be allocated.


---
Diffs of the changes:  (+1 -1)

 llvm-prof.cpp |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)


Index: llvm/tools/llvm-prof/llvm-prof.cpp
diff -u llvm/tools/llvm-prof/llvm-prof.cpp:1.34 llvm/tools/llvm-prof/llvm-prof.cpp:1.35
--- llvm/tools/llvm-prof/llvm-prof.cpp:1.34	Sun May  6 18:45:49 2007
+++ llvm/tools/llvm-prof/llvm-prof.cpp	Mon May  7 13:50:07 2007
@@ -117,7 +117,7 @@
 
     // Read in the bytecode file...
     std::string ErrorMessage;
-    Module *M;
+    Module *M = 0;
     if (MemoryBuffer *Buffer = MemoryBuffer::getFileOrSTDIN(BytecodeFile,
                                                             &ErrorMessage)) {
       M = ParseBitcodeFile(Buffer, &ErrorMessage);






More information about the llvm-commits mailing list