[cfe-commits] r38952 - /cfe/cfe/trunk/Basic/SourceBuffer.cpp

sabre at cs.uiuc.edu sabre at cs.uiuc.edu
Wed Jul 11 09:26:11 PDT 2007


Author: sabre
Date: Wed Jul 11 11:26:10 2007
New Revision: 38952

URL: http://llvm.org/viewvc/llvm-project?rev=38952&view=rev
Log:
Make this work with llvm cvs

Modified:
    cfe/cfe/trunk/Basic/SourceBuffer.cpp

Modified: cfe/cfe/trunk/Basic/SourceBuffer.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/cfe/trunk/Basic/SourceBuffer.cpp?rev=38952&r1=38951&r2=38952&view=diff

==============================================================================
--- cfe/cfe/trunk/Basic/SourceBuffer.cpp (original)
+++ cfe/cfe/trunk/Basic/SourceBuffer.cpp Wed Jul 11 11:26:10 2007
@@ -110,9 +110,12 @@
 };
 }
 
-SourceBufferFile::SourceBufferFile(const sys::Path &Filename) : File(Filename) {
+SourceBufferFile::SourceBufferFile(const sys::Path &Filename) {
   // FIXME: This does an extra stat syscall to figure out the size, but we
   // already know the size!
+  bool Failure = File.open(Filename);
+  assert(!Failure && "Can't open file??");
+  
   File.map();
   
   size_t Size = File.size();





More information about the cfe-commits mailing list