Commit 8146d656 authored by Jérémie Dudouet's avatar Jérémie Dudouet
Browse files

debug

parent 3560cc65
......@@ -49,6 +49,7 @@ bool TstampFilter::Initialize(std::string tstampFile, int tolerance, int id)
fTstampFile = tstampFile;
//fTstampFile = GetConfPath() + fTstampFile;
cout<<fBinaryFormat<<endl;
if(fBinaryFormat) {
if( (fTstampFILE = fopen(fTstampFile.c_str(),"rb")) == NULL) {
cout << "Error opening " << fTstampFile << endl;
......@@ -57,7 +58,7 @@ bool TstampFilter::Initialize(std::string tstampFile, int tolerance, int id)
return false;
}
}
if( (fTstampFILE = fopen(fTstampFile.c_str(),"r")) == NULL) {
else if( (fTstampFILE = fopen(fTstampFile.c_str(),"r")) == NULL) {
cout << "Error opening " << fTstampFile << endl;
//*error_code = 133;
//Log << dolog;
......@@ -70,6 +71,7 @@ bool TstampFilter::Initialize(std::string tstampFile, int tolerance, int id)
int nn;
if(fBinaryFormat) nn = fread (&fTimestamp,1,sizeof (fTimestamp),fTstampFILE)/sizeof(fTimestamp);
else nn = fscanf(fTstampFILE, "%lld", &fTimestamp);
cout<<nn<<endl;
if(nn != 1) {
cout << "Error reading " << fTstampFile << endl;
//*error_code = 134;
......
......@@ -61,7 +61,7 @@ void TSFilter::process_initialise ( UInt_t *error_code )
cout << endl;
if(fTstampFilterFile.size()) {
fTstampFilter = new TstampFilter(GetConfPath()+fTstampFilterFile, fTstampFilterTolerance, fTstampFilterId);
fTstampFilter = new TstampFilter(GetConfPath()+fTstampFilterFile, fTstampFilterTolerance, fTstampFilterId, fBinary);
if( !fTstampFilter->IsReady() ) {
*error_code = 200 + rerr;
return;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment