]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
remove duplicate checking (bug #3927)
authorRussell Bryant <russell@russellbryant.com>
Sat, 2 Apr 2005 17:41:19 +0000 (17:41 +0000)
committerRussell Bryant <russell@russellbryant.com>
Sat, 2 Apr 2005 17:41:19 +0000 (17:41 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/v1-0@5359 65c4cc65-6c06-0410-ace0-fbb531ad65f3

pbx/pbx_spool.c

index 0c1249d06c3906db50f71827039dd9e885b21e5c..fcf50c27112b0693e91ba936ee0031a29ae52055 100755 (executable)
@@ -92,10 +92,8 @@ static int apply_outgoing(struct outgoing *o, char *fn, FILE *f)
        char buf[256];
        char *c, *c2;
        int lineno = 0;
-       while(!feof(f)) {
-               fgets(buf, sizeof(buf), f);
+       while(fgets(buf, sizeof(buf), f)) {
                lineno++;
-               if (!ast_strlen_zero(buf)) {
                        /* Trim comments */
                        c = buf;
                        while ((c = strchr(c, '#'))) {
@@ -184,7 +182,6 @@ static int apply_outgoing(struct outgoing *o, char *fn, FILE *f)
                                } else
                                        ast_log(LOG_NOTICE, "Syntax error at line %d of %s\n", lineno, fn);
                        }
-               }
        }
        strncpy(o->fn, fn, sizeof(o->fn) - 1);
        if (ast_strlen_zero(o->tech) || ast_strlen_zero(o->dest) || (ast_strlen_zero(o->app) && ast_strlen_zero(o->exten))) {