[asterisk-commits] juggie: branch juggie/NoLossCDR r78523 - in /team/juggie/NoLossCDR: ./ apps/ ...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue Aug 7 17:20:29 CDT 2007


Author: juggie
Date: Tue Aug  7 17:20:20 2007
New Revision: 78523

URL: http://svn.digium.com/view/asterisk?view=rev&rev=78523
Log:
Merged revisions 78465,78498 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/team/group/CDRfix5

........
r78465 | automerge | 2007-08-07 16:27:48 -0400 (Tue, 07 Aug 2007) | 1 line

automerge commit
........
r78498 | automerge | 2007-08-07 17:27:41 -0400 (Tue, 07 Aug 2007) | 1 line

automerge commit
........

Modified:
    team/juggie/NoLossCDR/   (props changed)
    team/juggie/NoLossCDR/apps/app_voicemail.c
    team/juggie/NoLossCDR/res/res_config_odbc.c
    team/juggie/NoLossCDR/res/res_odbc.c

Propchange: team/juggie/NoLossCDR/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Propchange: team/juggie/NoLossCDR/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Tue Aug  7 17:20:20 2007
@@ -1,1 +1,1 @@
-/team/group/CDRfix5:1-78448
+/team/group/CDRfix5:1-78522

Modified: team/juggie/NoLossCDR/apps/app_voicemail.c
URL: http://svn.digium.com/view/asterisk/team/juggie/NoLossCDR/apps/app_voicemail.c?view=diff&rev=78523&r1=78522&r2=78523
==============================================================================
--- team/juggie/NoLossCDR/apps/app_voicemail.c (original)
+++ team/juggie/NoLossCDR/apps/app_voicemail.c Tue Aug  7 17:20:20 2007
@@ -2675,9 +2675,9 @@
 	int newmsgs, oldmsgs;
 	
 	if(inboxcount(mailbox, &newmsgs, &oldmsgs))
+		return 0;
+	else
 		return folder? oldmsgs: newmsgs;
-	else
-		return 0;
 }
 
 static int messagecount(const char *context, const char *mailbox, const char *folder)
@@ -2690,9 +2690,9 @@
 	sprintf(tmp,"%s@%s", mailbox, ast_strlen_zero(context)? "default": context);
 
 	if(inboxcount(tmp, &newmsgs, &oldmsgs))
+		return 0;
+	else
 		return folder? oldmsgs: newmsgs;
-	else
-		return 0;
 }
 
 #endif

Modified: team/juggie/NoLossCDR/res/res_config_odbc.c
URL: http://svn.digium.com/view/asterisk/team/juggie/NoLossCDR/res/res_config_odbc.c?view=diff&rev=78523&r1=78522&r2=78523
==============================================================================
--- team/juggie/NoLossCDR/res/res_config_odbc.c (original)
+++ team/juggie/NoLossCDR/res/res_config_odbc.c Tue Aug  7 17:20:20 2007
@@ -57,7 +57,7 @@
 struct custom_prepare_struct {
 	const char *sql;
 	const char *extra;
-	va_list *ap;
+	va_list ap;
 };
 
 static SQLHSTMT custom_prepare(struct odbc_obj *obj, void *data)
@@ -67,7 +67,8 @@
 	const char *newparam, *newval;
 	SQLHSTMT stmt;
 	va_list ap;
-	va_copy(ap, *(cps->ap));
+
+	va_copy(ap, cps->ap);
 
 	res = SQLAllocHandle(SQL_HANDLE_STMT, obj->con, &stmt);
 	if ((res != SQL_SUCCESS) && (res != SQL_SUCCESS_WITH_INFO)) {
@@ -127,8 +128,9 @@
 	SQLSMALLINT nullable;
 	SQLLEN indicator;
 	va_list aq;
-	struct custom_prepare_struct cps = { .sql = sql, .ap = &ap };
-	
+	struct custom_prepare_struct cps = { .sql = sql };
+
+	va_copy(cps.ap, ap);
 	va_copy(aq, ap);
 
 	if (!table)
@@ -269,9 +271,10 @@
 	SQLSMALLINT decimaldigits;
 	SQLSMALLINT nullable;
 	SQLLEN indicator;
-	struct custom_prepare_struct cps = { .sql = sql, .ap = &ap };
-
+	struct custom_prepare_struct cps = { .sql = sql };
 	va_list aq;
+
+	va_copy(cps.ap, ap);
 	va_copy(aq, ap);
 
 	if (!table)
@@ -399,8 +402,9 @@
 	const char *newparam, *newval;
 	int res;
 	va_list aq;
-	struct custom_prepare_struct cps = { .sql = sql, .ap = &ap, .extra = lookup };
-	
+	struct custom_prepare_struct cps = { .sql = sql, .extra = lookup };
+
+	va_copy(cps.ap, ap);
 	va_copy(aq, ap);
 	
 	if (!table)

Modified: team/juggie/NoLossCDR/res/res_odbc.c
URL: http://svn.digium.com/view/asterisk/team/juggie/NoLossCDR/res/res_odbc.c?view=diff&rev=78523&r1=78522&r2=78523
==============================================================================
--- team/juggie/NoLossCDR/res/res_odbc.c (original)
+++ team/juggie/NoLossCDR/res/res_odbc.c Tue Aug  7 17:20:20 2007
@@ -486,10 +486,7 @@
 	res = SQLAllocHandle(SQL_HANDLE_DBC, obj->parent->env, &obj->con);
 
 	if ((res != SQL_SUCCESS) && (res != SQL_SUCCESS_WITH_INFO)) {
-
 		ast_log(LOG_WARNING, "res_odbc: Error AllocHDB %d\n", res);
-		SQLFreeHandle(SQL_HANDLE_ENV, obj->parent->env);
-
 		ast_mutex_unlock(&obj->lock);
 		return ODBC_FAIL;
 	}




More information about the asterisk-commits mailing list