Commit 8e535189be36cfc697410b6ddaf4b384c919a44e

Authored by Michael Mayer
1 parent 7e03bf60

fixed minor bug

Showing 1 changed file with 5 additions and 5 deletions
src/ctselect/ctselect.cpp
... ... @@ -664,7 +664,7 @@ void ctselect::select_events(GCTAObservation* obs, const std::string& filename)
664 664 GEbounds ebounds = find_ebounds(obs,list->ebounds());
665 665  
666 666 // Check if energy bounds are valid
667   - if (ebounds.size() > 0) {
  667 + if (ebounds.size() >= 1) {
668 668  
669 669 // Write ebounds to log
670 670 if (logTerse()) {
... ... @@ -1093,11 +1093,11 @@ GEbounds ctselect::find_ebounds(GCTAObservation* obs, const GEbounds& list_eboun
1093 1093 if (list_ebounds.size() >= 1) {
1094 1094  
1095 1095 // Make sure the user parameters don't condradict previous selections
1096   - if (emin < ebounds.emin(0).TeV()) {
1097   - emin = ebounds.emin(0).TeV();
  1096 + if (emin < list_ebounds.emin(0).TeV()) {
  1097 + emin = list_ebounds.emin(0).TeV();
1098 1098 }
1099   - if (emax > ebounds.emax(0).TeV()) {
1100   - emax = ebounds.emax(0).TeV();
  1099 + if (emax > list_ebounds.emax(0).TeV()) {
  1100 + emax = list_ebounds.emax(0).TeV();
1101 1101 }
1102 1102 } //endif: ebounds were valid
1103 1103  
... ...