ValidateRootFile.C
Go to the documentation of this file.
1 #include "TFile.h"
2 
3 void ValidateRootFile(char* fIn) {
4  TFile file(fIn);
5 
6  if(file.IsZombie() || file.TestBit(TFile::kRecovered)) {
7  std::cout << fIn << " FILE TEST: File is corrupted in some manner. Do not use!" << std::endl;
8  exit(0);
9  }
10  else {
11  std::cout << fIn << " FILE TEST: Appears to be fine. More testing may be required though." << std::endl;
12  exit(1);
13  }
14 
15 }
void ValidateRootFile(char *fIn)
OStream cout
Definition: OStream.cxx:6
exit(0)
TFile * file
Definition: cellShifts.C:17