[svn-commits] oej: branch oej/multiparking r64456 - in /team/oej/multiparking: ./ channels/...

svn-commits at lists.digium.com svn-commits at lists.digium.com
Tue May 15 13:49:50 MST 2007


Author: oej
Date: Tue May 15 15:49:49 2007
New Revision: 64456

URL: http://svn.digium.com/view/asterisk?view=rev&rev=64456
Log:
Reset automerge, resolve conflict, go to bed.

Modified:
    team/oej/multiparking/   (props changed)
    team/oej/multiparking/channels/chan_zap.c
    team/oej/multiparking/configs/zapata.conf.sample
    team/oej/multiparking/res/res_features.c

Propchange: team/oej/multiparking/
------------------------------------------------------------------------------
    automerge = http://edvina.net/training/

Propchange: team/oej/multiparking/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Propchange: team/oej/multiparking/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Tue May 15 15:49:49 2007
@@ -1,1 +1,1 @@
-/trunk:1-64407
+/trunk:1-64455

Modified: team/oej/multiparking/channels/chan_zap.c
URL: http://svn.digium.com/view/asterisk/team/oej/multiparking/channels/chan_zap.c?view=diff&rev=64456&r1=64455&r2=64456
==============================================================================
--- team/oej/multiparking/channels/chan_zap.c (original)
+++ team/oej/multiparking/channels/chan_zap.c Tue May 15 15:49:49 2007
@@ -7486,7 +7486,7 @@
 	unsigned int code1, code2, code3;
 	int numvals;
 
-	numvals = sscanf(pcstring, "%d.%d.%d", &code1, &code2, &code3);
+	numvals = sscanf(pcstring, "%d-%d-%d", &code1, &code2, &code3);
 	if (numvals == 1)
 		return code1;
 	if (numvals == 3)

Modified: team/oej/multiparking/configs/zapata.conf.sample
URL: http://svn.digium.com/view/asterisk/team/oej/multiparking/configs/zapata.conf.sample?view=diff&rev=64456&r1=64455&r2=64456
==============================================================================
--- team/oej/multiparking/configs/zapata.conf.sample (original)
+++ team/oej/multiparking/configs/zapata.conf.sample Tue May 15 15:49:49 2007
@@ -676,7 +676,7 @@
 
 ; Point code of the linkset.  For ITU, this is the decimal number
 ; format of the point code.  For ANSI, this can either be in decimal
-; number format or in the xxx.xxx.xxx format
+; number format or in the xxx-xxx-xxx format
 ;pointcode = 1
 
 ; Point code of node adjacent to this signaling link (Possibly the STP between you and

Modified: team/oej/multiparking/res/res_features.c
URL: http://svn.digium.com/view/asterisk/team/oej/multiparking/res/res_features.c?view=diff&rev=64456&r1=64455&r2=64456
==============================================================================
--- team/oej/multiparking/res/res_features.c (original)
+++ team/oej/multiparking/res/res_features.c Tue May 15 15:49:49 2007
@@ -385,23 +385,6 @@
 		return AST_DEVICE_INUSE;
 }
 
-/*!
- * \brief Check to see if a parking space is in use
- * \return non-zero if in use, zero if not in use
- * \note Assumes parking_lock is locked
- */
-static int check_parking_space_inuse(int space)
-{
-	struct parkeduser *pu;
-
-	for (pu = parkinglot; pu; pu = pu->next) {
-		if (pu->parkingnum == space)
-			return 1;
-	}
-
-	return 0;
-}
-
 /*! \brief Park a call 
  	\note We put the user in the parking list, then wake up the parking thread to be sure it looks
 	after these channels too */
@@ -439,19 +422,15 @@
 	parkingexten = pbx_builtin_getvar_helper(chan, "PARKINGEXTEN");
 	if (!ast_strlen_zero(parkingexten)) {
 		if (ast_exists_extension(NULL, parkinglot->parking_con, parkingexten, 1, NULL)) {
-			ast_log(LOG_WARNING, "Requested parking extension already exists: %s@%s\n", parkingexten, parkinglot->parking_con);
+			ast_mutex_unlock(&parking_lock);
 			parkinglot_unref(parkinglot);
 			ASTOBJ_UNLOCK(parkinglot);
+			free(pu);
+			ast_log(LOG_WARNING, "Requested parking extension already exists: %s@%s\n", parkingexten, parking_con);
 			return 0;	/* Continue execution if possible */
 		}
 		ast_copy_string(pu->parkingexten, parkingexten, sizeof(pu->parkingexten));
 		x = atoi(parkingexten);
-		if (check_parking_space_inuse(x)) {
-			ast_mutex_unlock(&parking_lock);
-			free(pu);
-			ast_log(LOG_WARNING, "Requested parking space %d via PARKINGEXTEN, but it is in use!\n", x);
-			return -1;
-		}
 	} else {
 		/* Select parking space within range */
 		parking_range = parkinglot->parking_stop - parkinglot->parking_start + 1;



More information about the svn-commits mailing list