Unsigned values are never less than zero

This commit is contained in:
Travis Cross 2013-05-26 10:57:07 +00:00
parent 1637a08206
commit e1a773406d
1 changed files with 1 additions and 6 deletions

View File

@ -603,12 +603,7 @@ SWITCH_MODULE_LOAD_FUNCTION(mod_json_cdr_load)
}
}
if (globals.retries < 0) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Retries is negative, setting to 0\n");
globals.retries = 0;
}
if (globals.retries && globals.delay <= 0) {
if (globals.retries && globals.delay) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Retries set but delay 0 setting to 5000ms\n");
globals.delay = 5000;
}