[svn-commits] russell: branch russell/events r92508 - in /team/russell/events: ./ main/

SVN commits to the Digium repositories svn-commits at lists.digium.com
Wed Dec 12 11:18:44 CST 2007


Author: russell
Date: Wed Dec 12 11:18:44 2007
New Revision: 92508

URL: http://svn.digium.com/view/asterisk?view=rev&rev=92508
Log:
resolve, reset ...

Modified:
    team/russell/events/   (props changed)
    team/russell/events/configure
    team/russell/events/configure.ac
    team/russell/events/main/asterisk.c

Propchange: team/russell/events/
------------------------------------------------------------------------------
    automerge = *

Propchange: team/russell/events/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Propchange: team/russell/events/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Wed Dec 12 11:18:44 2007
@@ -1,1 +1,1 @@
-/trunk:1-92446
+/trunk:1-92507

Modified: team/russell/events/configure
URL: http://svn.digium.com/view/asterisk/team/russell/events/configure?view=diff&rev=92508&r1=92507&r2=92508
==============================================================================
--- team/russell/events/configure (original)
+++ team/russell/events/configure Wed Dec 12 11:18:44 2007
@@ -1,5 +1,5 @@
 #! /bin/sh
-# From configure.ac Revision: 89700 .
+# From configure.ac Revision: 92447 .
 # Guess values for system-dependent variables and create Makefiles.
 # Generated by GNU Autoconf 2.61.
 #
@@ -36063,9 +36063,9 @@
          exit 1
 	  fi
    else
-      { echo "$as_me:$LINENO: checking for PQexec in -lpq" >&5
-echo $ECHO_N "checking for PQexec in -lpq... $ECHO_C" >&6; }
-if test "${ac_cv_lib_pq_PQexec+set}" = set; then
+      { echo "$as_me:$LINENO: checking for PQescapeStringConn in -lpq" >&5
+echo $ECHO_N "checking for PQescapeStringConn in -lpq... $ECHO_C" >&6; }
+if test "${ac_cv_lib_pq_PQescapeStringConn+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
@@ -36083,11 +36083,11 @@
 #ifdef __cplusplus
 extern "C"
 #endif
-char PQexec ();
+char PQescapeStringConn ();
 int
 main ()
 {
-return PQexec ();
+return PQescapeStringConn ();
   ;
   return 0;
 }
@@ -36110,21 +36110,21 @@
 	 test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_pq_PQexec=yes
+  ac_cv_lib_pq_PQescapeStringConn=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-	ac_cv_lib_pq_PQexec=no
+	ac_cv_lib_pq_PQescapeStringConn=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_pq_PQexec" >&5
-echo "${ECHO_T}$ac_cv_lib_pq_PQexec" >&6; }
-if test $ac_cv_lib_pq_PQexec = yes; then
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_pq_PQescapeStringConn" >&5
+echo "${ECHO_T}$ac_cv_lib_pq_PQescapeStringConn" >&6; }
+if test $ac_cv_lib_pq_PQescapeStringConn = yes; then
 
 cat >>confdefs.h <<_ACEOF
 #define HAVE_PGSQL 1
@@ -36133,7 +36133,7 @@
 fi
 
 
-      if test "${ac_cv_lib_pq_PQexec}" = "yes"; then
+      if test "${ac_cv_lib_pq_PQescapeStringConn}" = "yes"; then
          PGSQL_LIB="-L${PGSQL_libdir} -lpq -lz"
          PGSQL_INCLUDE="-I${PGSQL_includedir}"
          PBX_PGSQL=1

Modified: team/russell/events/configure.ac
URL: http://svn.digium.com/view/asterisk/team/russell/events/configure.ac?view=diff&rev=92508&r1=92507&r2=92508
==============================================================================
--- team/russell/events/configure.ac (original)
+++ team/russell/events/configure.ac Wed Dec 12 11:18:44 2007
@@ -898,10 +898,10 @@
          exit 1
 	  fi
    else 
-      AC_CHECK_LIB([pq], [PQexec], AC_DEFINE_UNQUOTED([HAVE_PGSQL], 1,
+      AC_CHECK_LIB([pq], [PQescapeStringConn], AC_DEFINE_UNQUOTED([HAVE_PGSQL], 1,
       [Define to indicate the PostgreSQL library]), [], -L${PGSQL_libdir} -lz)
 
-      if test "${ac_cv_lib_pq_PQexec}" = "yes"; then
+      if test "${ac_cv_lib_pq_PQescapeStringConn}" = "yes"; then
          PGSQL_LIB="-L${PGSQL_libdir} -lpq -lz"
          PGSQL_INCLUDE="-I${PGSQL_includedir}"
          PBX_PGSQL=1

Modified: team/russell/events/main/asterisk.c
URL: http://svn.digium.com/view/asterisk/team/russell/events/main/asterisk.c?view=diff&rev=92508&r1=92507&r2=92508
==============================================================================
--- team/russell/events/main/asterisk.c (original)
+++ team/russell/events/main/asterisk.c Wed Dec 12 11:18:44 2007
@@ -1985,7 +1985,7 @@
 
 static char **ast_el_strtoarr(char *buf)
 {
-	char **match_list = NULL, *retstr;
+	char **match_list = NULL, **match_list_tmp, *retstr;
 	size_t match_list_len;
 	int matches = 0;
 
@@ -1996,8 +1996,12 @@
 			break;
 		if (matches + 1 >= match_list_len) {
 			match_list_len <<= 1;
-			if (!(match_list = ast_realloc(match_list, match_list_len * sizeof(char *)))) {
-				/* TODO: Handle memory allocation failure */
+			if ((match_list_tmp = ast_realloc(match_list, match_list_len * sizeof(char *)))) {
+				match_list = match_list_tmp;
+			} else {
+				if (match_list)
+					ast_free(match_list);
+				return (char **) NULL;
 			}
 		}
 
@@ -2008,8 +2012,12 @@
 		return (char **) NULL;
 
 	if (matches >= match_list_len) {
-		if (!(match_list = ast_realloc(match_list, (match_list_len + 1) * sizeof(char *)))) {
-			/* TODO: Handle memory allocation failure */
+		if ((match_list_tmp = ast_realloc(match_list, (match_list_len + 1) * sizeof(char *)))) {
+			match_list = match_list_tmp;
+		} else {
+			if (match_list)
+				ast_free(match_list);
+			return (char **) NULL;
 		}
 	}
 




More information about the svn-commits mailing list