solved bug on the number of chans of multiSlsDetector

git-svn-id: file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorSoftware@697 951219d9-93cf-4727-9268-0efd64621fa3
This commit is contained in:
bergamaschi
2013-11-21 15:57:57 +00:00
parent 3b3e4eb8c3
commit 1ed2ba63b5
13 changed files with 125 additions and 21 deletions

View File

@ -341,12 +341,12 @@ class fileIOStatic {
\param offset start channel number
\returns OK or FAIL if it could not write the file or data=NULL
*/
static int writeDataFile(ofstream &outfile, int nch, double *data, double *err=NULL, double *ang=NULL, char dataformat='f', int offset=0){ \
static int writeDataFile(ofstream &outfile, int nch, double *data, double *err=NULL, double *ang=NULL, char dataformat='f', int offset=0){
int idata; \
if (data==NULL) { \
if (data==NULL || nch==0) { \
cout << "No data to write!" << endl; \
return slsDetectorDefs::FAIL; \
} \
} \
for (int ichan=0; ichan<nch; ichan++) { \
if (ang==NULL) { \
outfile << ichan+offset << " "; \