~damg/ubuntu/quantal/asterisk/LP1097687

« back to all changes in this revision

Viewing changes to apps/app_directory.c

  • Committer: Bazaar Package Importer
  • Author(s): Jean-Michel Dault
  • Date: 2010-02-16 14:08:54 UTC
  • mfrom: (1.2.5 upstream) (8.3.4 sid)
  • Revision ID: james.westby@ubuntu.com-20100216140854-rb2godspb9lduazl
Tags: 1:1.6.2.2-1ubuntu1
* Merge from Debian: security update
  * Changes:
  - debian/control: Change Maintainer
  - debian/control: Removed Uploaders field.
  - debian/control: Removed Debian Vcs-Svn entry and replaced with
      ubuntu-voip Vcs-Bzr, to reflect divergence in packages.
  - debian/asterisk.init : chown /dev/dahdi
  - debian/backports/hardy : add file
  - debian/backports/asterisk.init.hardy : add file

Show diffs side-by-side

added added

removed removed

Lines of Context:
30
30
 ***/
31
31
#include "asterisk.h"
32
32
 
33
 
ASTERISK_FILE_VERSION(__FILE__, "$Revision: 165318 $")
 
33
ASTERISK_FILE_VERSION(__FILE__, "$Revision: 234896 $")
34
34
 
35
35
#include <ctype.h>
36
36
 
525
525
                strsep(&bufptr, ",");
526
526
                pos = strsep(&bufptr, ",");
527
527
 
 
528
                /* No name to compare against */
 
529
                if (ast_strlen_zero(pos)) {
 
530
                        continue;
 
531
                }
 
532
 
528
533
                res = 0;
529
534
                if (ast_test_flag(&flags, OPT_LISTBYLASTNAME)) {
530
535
                        res = check_match(&item, context, pos, v->name, ext, 0 /* use_first_name */);
647
652
        char ext[10] = "";
648
653
 
649
654
        if (digit == '0' && !goto_exten(chan, S_OR(dialcontext, "default"), "o")) {
650
 
                return 0;
 
655
                return digit;
651
656
        }
652
657
 
653
658
        if (digit == '*' && !goto_exten(chan, S_OR(dialcontext, "default"), "a")) {
654
 
                return 0;
 
659
                return digit;
655
660
        }
656
661
 
657
662
        ext[0] = digit;
803
808
                                        "dir-firstlast", AST_DIGIT_ANY);
804
809
                        }
805
810
                        if (!res) {
806
 
                                ast_stream_and_wait(chan, "dir-usingkeypad", AST_DIGIT_ANY);
 
811
                                res = ast_stream_and_wait(chan, "dir-usingkeypad", AST_DIGIT_ANY);
807
812
                        }
808
813
                }
809
814
                ast_stopstream(chan);