[svn-commits] trunk r197 - /trunk/asterisk-ooh323c/src/chan_h323.c

svn-commits at lists.digium.com svn-commits at lists.digium.com
Thu Feb 9 09:59:07 MST 2006


Author: objsys
Date: Thu Feb  9 10:59:06 2006
New Revision: 197

URL: http://svn.digium.com/view/asterisk-addons?rev=197&view=rev
Log:
allowed \#\*\, chars in dailedDigit

Modified:
    trunk/asterisk-ooh323c/src/chan_h323.c

Modified: trunk/asterisk-ooh323c/src/chan_h323.c
URL: http://svn.digium.com/view/asterisk-addons/trunk/asterisk-ooh323c/src/chan_h323.c?rev=197&r1=196&r2=197&view=diff
==============================================================================
--- trunk/asterisk-ooh323c/src/chan_h323.c (original)
+++ trunk/asterisk-ooh323c/src/chan_h323.c Thu Feb  9 10:59:06 2006
@@ -1271,8 +1271,7 @@
          i=0;
          while(*(p->callerid_num+i) != '\0')
          {
-            if(!isdigit(*(p->callerid_num+i)))
-               break;
+            if(!isdigit(*(p->callerid_num+i))) { break; }
             i++;
          }
          if(*(p->callerid_num+i) == '\0')
@@ -1306,30 +1305,34 @@
       }
   
 
-     if(!ast_strlen_zero(p->exten))  
-     {
-         for(i=0; *(p->exten+i) != '\0'; i++)
-         {
-            if(!isdigit(*(p->exten+i)))
-               break;
-         }
-         if(*(p->exten+i) == '\0'){
+      if(!ast_strlen_zero(p->exten))  
+      {
+         const char* pexten = p->exten;
+         while(*pexten != '\0') {
+            if(!(isdigit(*pexten)) && 
+               *pexten != '#' && *pexten != '*' && *pexten != ',') { 
+               break; 
+            }
+            pexten++;
+         }
+         if(*pexten == '\0') {
             ooCallSetCalledPartyNumber(call, p->exten);
             ooCallAddRemoteAliasDialedDigits(call, p->exten);
          }
-         else
+         else {
            ooCallAddRemoteAliasH323ID(call, p->exten);
-     }
-
-     if(gH323Debug)
-     {
-       char prefsBuf[256];
-       ast_codec_pref_string(&p->prefs, prefsBuf, 256);
-       ast_verbose(" Outgoing call %s(%s) - Codec prefs - %s\n", 
+         }
+      }
+
+      if(gH323Debug)
+      {
+         char prefsBuf[256];
+         ast_codec_pref_string(&p->prefs, prefsBuf, 256);
+         ast_verbose(" Outgoing call %s(%s) - Codec prefs - %s\n", 
                     p->username?p->username:"NULL", call->callToken, prefsBuf);
-     }
-
-     ooh323c_set_capability_for_call(call, &p->prefs, p->capability, 
+      }
+
+      ooh323c_set_capability_for_call(call, &p->prefs, p->capability, 
                                      p->dtmfmode);
    
       configure_local_rtp(p, call);



More information about the svn-commits mailing list