Allow 0 retry time (bug #3630)
[asterisk/asterisk.git] / apps / app_queue.c
index d758484..deb3bca 100755 (executable)
@@ -2484,7 +2484,7 @@ static void reload_queues(void)
                                        ast_mutex_lock(&q->lock);
                                /* Re-initialize the queue */
                                ast_clear_flag(q, QUEUE_FLAG_DEAD);
                                        ast_mutex_lock(&q->lock);
                                /* Re-initialize the queue */
                                ast_clear_flag(q, QUEUE_FLAG_DEAD);
-                               q->retry = 0;
+                               q->retry = DEFAULT_RETRY;
                                q->timeout = -1;
                                q->maxlen = 0;
                                q->announcefrequency = 0;
                                q->timeout = -1;
                                q->maxlen = 0;
                                q->announcefrequency = 0;
@@ -2612,7 +2612,7 @@ static void reload_queues(void)
                                        }
                                        var = var->next;
                                }
                                        }
                                        var = var->next;
                                }
-                               if (q->retry < 1)
+                               if (q->retry < 0)
                                        q->retry = DEFAULT_RETRY;
                                if (q->timeout < 0)
                                        q->timeout = DEFAULT_TIMEOUT;
                                        q->retry = DEFAULT_RETRY;
                                if (q->timeout < 0)
                                        q->timeout = DEFAULT_TIMEOUT;