Changeset 173
- Timestamp:
- 03/02/10 14:22:14 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Evidence/DColl.cc
r172 r173 151 151 char ErrMsg[200]; 152 152 regerror(Ret, &RegEx[i], ErrMsg, sizeof(ErrMsg)); 153 State( WARN, "Error compiling regular expression '%s' (%s)", Token, ErrMsg);153 State(FATAL, "Error compiling regular expression '%s' (%s)", Token, ErrMsg); 154 154 } 155 155 else { 156 156 if ((Token=strtok(NULL, ": \t")) != NULL) MinChange[i] = atof(Token); 157 157 else MinChange[i] = 0; 158 158 159 if ((Token=strtok(NULL, "")) != NULL) HistSize[i] = atoi(Token)*1024; 159 else HistSize[i] = MIN_HIST_SIZE; 160 if (HistSize[i] < MIN_HIST_SIZE) HistSize[i] = MIN_HIST_SIZE; 160 else HistSize[i] = 0; 161 161 } 162 162 Pos += Len; … … 473 473 // Set minimum required change by comparing to regular expressions 474 474 New.MinAbsChange = 0; 475 New.HistSize = MIN_HIST_SIZE;475 New.HistSize = 0; 476 476 for (int i=0; i<RegExCount; i++) { 477 477 if (regexec(&RegEx[i], Name.c_str(), (size_t) 0, NULL, 0) == 0) { 478 478 New.MinAbsChange = MinChange[i]; 479 New.HistSize = HistSize[i]; 480 } 481 } 479 if (HistSize[i] != 0) New.HistSize = HistSize[i]; 480 } 481 } 482 483 // At least 3*sizeof(int) 484 if (New.HistSize < MIN_HIST_SIZE) New.HistSize = MIN_HIST_SIZE; 482 485 483 486 // Create history service
Note:
See TracChangeset
for help on using the changeset viewer.