[asterisk-commits] may: trunk r232853 - in /trunk/addons: ./ ooh323c/src/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Dec 3 14:26:58 CST 2009


Author: may
Date: Thu Dec  3 14:26:55 2009
New Revision: 232853

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=232853
Log:
jitterbuffer setup correction
correction of double pointer references from previous rev

Modified:
    trunk/addons/chan_ooh323.c
    trunk/addons/ooh323c/src/ooh245.c
    trunk/addons/ooh323c/src/ooh323.c

Modified: trunk/addons/chan_ooh323.c
URL: http://svnview.digium.com/svn/asterisk/trunk/addons/chan_ooh323.c?view=diff&rev=232853&r1=232852&r2=232853
==============================================================================
--- trunk/addons/chan_ooh323.c (original)
+++ trunk/addons/chan_ooh323.c Thu Dec  3 14:26:55 2009
@@ -14,6 +14,8 @@
  *
  *****************************************************************************/
 
+/* Reworked version I, Nov-2009, by Alexandr Anikin, may at telecom-service.ru */
+
 
 /*** MODULEINFO
 	<defaultenabled>no</defaultenabled>
@@ -94,6 +96,7 @@
 	.type = type,
 	.description = tdesc,
 	.capabilities = -1,
+	.properties = AST_CHAN_TP_WANTSJITTER | AST_CHAN_TP_CREATESJITTER,
 	.requester = ooh323_request,
 	.send_digit_begin = ooh323_digit_begin,
 	.send_digit_end = ooh323_digit_end,
@@ -1015,7 +1018,7 @@
 		ast_update_use_count();
 	  
 	} else {
-		ast_log(LOG_DEBUG, "No call to hangup\n" );
+		ast_debug(1, "No call to hangup\n" );
 	}
 	
 	if (gH323Debug)
@@ -1325,6 +1328,8 @@
 static int ooh323_fixup(struct ast_channel *oldchan, struct ast_channel *newchan)
 {
 	struct ooh323_pvt *p = newchan->tech_pvt;
+
+	if (!p) return -1;
 
 	if (gH323Debug)
 		ast_verbose("--- ooh323c ooh323_fixup\n");
@@ -3077,14 +3082,6 @@
 		.onModeChanged = onModeChanged
 	};
 
-	ast_log(LOG_NOTICE, 
-		"---------------------------------------------------------------------------------\n"
-		"---  ******* IMPORTANT NOTE ***********\n"
-		"---\n"
-		"---  This module is currently unsupported.  Use it at your own risk.\n"
-		"---\n"
-		"---------------------------------------------------------------------------------\n");
-
 	myself = ast_module_info->self;
 
 	h225Callbacks.onReceivedSetup = &ooh323_onReceivedSetup;
@@ -3625,7 +3622,7 @@
 	enum ast_rtp_glue_result res = AST_RTP_GLUE_RESULT_LOCAL;
 
 	if (!(p = (struct ooh323_pvt *) chan->tech_pvt))
-	return AST_RTP_GLUE_RESULT_FORBID;
+		return AST_RTP_GLUE_RESULT_FORBID;
 
 	if (!(p->rtp)) {
 		return AST_RTP_GLUE_RESULT_FORBID;
@@ -3634,6 +3631,10 @@
 	*rtp = p->rtp ? ao2_ref(p->rtp, +1), p->rtp : NULL;
 
 	res = AST_RTP_GLUE_RESULT_LOCAL;
+
+	if (ast_test_flag(&global_jbconf, AST_JB_FORCED)) {
+		res = AST_RTP_GLUE_RESULT_FORBID;
+	}
 
 	return res;
 }

Modified: trunk/addons/ooh323c/src/ooh245.c
URL: http://svnview.digium.com/svn/asterisk/trunk/addons/ooh323c/src/ooh245.c?view=diff&rev=232853&r1=232852&r2=232853
==============================================================================
--- trunk/addons/ooh323c/src/ooh245.c (original)
+++ trunk/addons/ooh323c/src/ooh245.c Thu Dec  3 14:26:55 2009
@@ -3201,7 +3201,7 @@
       ooFreeH245Message(call, ph245msg);
       return OO_FAILED;
    }
-   strcpy(*(char**)indication->u.userInput->u.alphanumeric, data);
+   strcpy(*(char**)&indication->u.userInput->u.alphanumeric, data);
    OOTRACEDBGA3 ("Built UserInputIndication_alphanumeric (%s, %s)\n", 
                  call->callType, call->callToken);
 
@@ -3264,7 +3264,7 @@
       ooFreeH245Message(call, ph245msg);
       return OO_FAILED;
    }
-   strcpy(*(char**)indication->u.userInput->u.signal->signalType, data);
+   strcpy(*(char**)&indication->u.userInput->u.signal->signalType, data);
    OOTRACEDBGA3 ("Built UserInputIndication_signal (%s, %s)\n", 
                  call->callType, call->callToken);
 

Modified: trunk/addons/ooh323c/src/ooh323.c
URL: http://svnview.digium.com/svn/asterisk/trunk/addons/ooh323c/src/ooh323.c?view=diff&rev=232853&r1=232852&r2=232853
==============================================================================
--- trunk/addons/ooh323c/src/ooh323.c (original)
+++ trunk/addons/ooh323c/src/ooh323.c Thu Dec  3 14:26:55 2009
@@ -2167,7 +2167,7 @@
                memFreePtr(pctxt, pPrefixEntry);
                return OO_FAILED;
             }
-            strcpy(*(char**)pPrefixEntry->prefix.u.dialedDigits, pAlias->value);
+            strcpy(*(char**)&pPrefixEntry->prefix.u.dialedDigits, pAlias->value);
             bValid = TRUE;
             break;
          default:
@@ -2220,7 +2220,7 @@
                memFreePtr(pctxt, pAliasEntry);
                return OO_FAILED;
             }
-            strcpy(*(char**)pAliasEntry->u.dialedDigits, pAlias->value);
+            strcpy(*(char**)&pAliasEntry->u.dialedDigits, pAlias->value);
             bValid = TRUE;
             break;
          case T_H225AliasAddress_h323_ID:
@@ -2249,7 +2249,7 @@
                memFreePtr(pctxt, pAliasEntry);               
                return OO_FAILED;
             }
-            strcpy(*(char**)pAliasEntry->u.url_ID, pAlias->value);
+            strcpy(*(char**)&pAliasEntry->u.url_ID, pAlias->value);
             bValid = TRUE;
             break;
          case T_H225AliasAddress_email_ID:
@@ -2262,7 +2262,7 @@
                            "alias entry \n");
                return OO_FAILED;
             }
-            strcpy(*(char**)pAliasEntry->u.email_ID, pAlias->value);
+            strcpy(*(char**)&pAliasEntry->u.email_ID, pAlias->value);
             bValid = TRUE;
             break;
          default:




More information about the asterisk-commits mailing list