[Pkg-voip-commits] r5792 - /asterisk/trunk/debian/patches/bristuff/

paravoid at alioth.debian.org paravoid at alioth.debian.org
Sun May 25 20:30:24 UTC 2008


Author: paravoid
Date: Sun May 25 20:30:23 2008
New Revision: 5792

URL: http://svn.debian.org/wsvn/pkg-voip/?sc=1&rev=5792
Log:
Whitespace-only changes to reduce the interdiff with stock bristuff-0.4.0-RC1

Modified:
    asterisk/trunk/debian/patches/bristuff/ast-device-state-CID
    asterisk/trunk/debian/patches/bristuff/ast-send-message-users
    asterisk/trunk/debian/patches/bristuff/feature-autoanswer
    asterisk/trunk/debian/patches/bristuff/feature-holdedcalls
    asterisk/trunk/debian/patches/bristuff/misc-app-devstate
    asterisk/trunk/debian/patches/bristuff/uniqueid-10-channel-ops-uniqueid
    asterisk/trunk/debian/patches/bristuff/uniqueid-30-app-chanspy
    asterisk/trunk/debian/patches/bristuff/uniqueid-40-manager
    asterisk/trunk/debian/patches/bristuff/xagi
    asterisk/trunk/debian/patches/bristuff/zapata-bri+euroisdn
    asterisk/trunk/debian/patches/bristuff/zapata-gsm

Modified: asterisk/trunk/debian/patches/bristuff/ast-device-state-CID
URL: http://svn.debian.org/wsvn/pkg-voip/asterisk/trunk/debian/patches/bristuff/ast-device-state-CID?rev=5792&op=diff
==============================================================================
--- asterisk/trunk/debian/patches/bristuff/ast-device-state-CID (original)
+++ asterisk/trunk/debian/patches/bristuff/ast-device-state-CID Sun May 25 20:30:23 2008
@@ -124,7 +124,7 @@
  /*! \brief Find a datastore on a channel */
  struct ast_datastore *ast_channel_datastore_find(struct ast_channel *chan, const struct ast_datastore_info *info, char *uid);
  
-+extern ast_mutex_t uniquelock;			
++extern ast_mutex_t uniquelock;
 +
 +/*! \brief Change the state of a channel and the callerid of the calling channel*/
 +int ast_setstate_and_callerid(struct ast_channel *chan, enum ast_channel_state state, char *cid_num, char *cid_name);

Modified: asterisk/trunk/debian/patches/bristuff/ast-send-message-users
URL: http://svn.debian.org/wsvn/pkg-voip/asterisk/trunk/debian/patches/bristuff/ast-send-message-users?rev=5792&op=diff
==============================================================================
--- asterisk/trunk/debian/patches/bristuff/ast-send-message-users (original)
+++ asterisk/trunk/debian/patches/bristuff/ast-send-message-users Sun May 25 20:30:23 2008
@@ -14,7 +14,7 @@
  	return 0;
  }
  
-+static char mandescr_message[] = 
++static char mandescr_message[] =
 +"Description: Send a message\n"
 +"Variables: \n"
 +"	Channel: The destination channel(e.g. SIP/phone1)\n"
@@ -48,7 +48,7 @@
 +	} else {
 +	    res = ast_send_message(tech, (char *)data, (char *)name, (char *)from, (char *)pdu, 1);
 +	}
-+	
++
 +	if (res) {
 +		astman_send_error(s, m, "Error sending message");
 +		return 0;

Modified: asterisk/trunk/debian/patches/bristuff/feature-autoanswer
URL: http://svn.debian.org/wsvn/pkg-voip/asterisk/trunk/debian/patches/bristuff/feature-autoanswer?rev=5792&op=diff
==============================================================================
--- asterisk/trunk/debian/patches/bristuff/feature-autoanswer (original)
+++ asterisk/trunk/debian/patches/bristuff/feature-autoanswer Sun May 25 20:30:23 2008
@@ -59,7 +59,7 @@
 +	struct aauser *next;
 +};
 +
-+ 
++
 +static struct aauser *aalot;
 +AST_MUTEX_DEFINE_STATIC(autoanswer_lock);
 +static pthread_t autoanswer_thread;
@@ -229,7 +229,7 @@
 +	}
 +	res = ast_masq_autoanswer_login(chan, data);
 +	ast_module_user_remove(u);
-+	return res; 
++	return res;
 +}
 +
 +int ast_autoanswer_login(struct ast_channel *chan, void *data)
@@ -288,7 +288,7 @@
 +		memset(pu, 0, sizeof(pu));
 +		ast_mutex_lock(&autoanswer_lock);
 +		chan->appl = "Autoanswer";
-+		chan->data = NULL; 
++		chan->data = NULL;
 +
 +		pu->chan = chan;
 +		if (chan->_state != AST_STATE_UP) {
@@ -317,7 +317,7 @@
 +		ast_mutex_unlock(&autoanswer_lock);
 +		/* Wake up the (presumably select()ing) thread */
 +		pthread_kill(autoanswer_thread, SIGURG);
-+		if (option_verbose > 1) 
++		if (option_verbose > 1)
 +			ast_verbose(VERBOSE_PREFIX_2 "Autoanswer login from %s for %s@%s.\n", pu->chan->name, pu->exten, pu->context);
 +			manager_event(EVENT_FLAG_CALL, "AutoanswerLogin",
 +                                "Channel: %s\r\n"
@@ -397,7 +397,7 @@
 +					f = ast_read(pu->chan);
 +					if (!f || ((f->frametype == AST_FRAME_CONTROL) && (f->subclass ==  AST_CONTROL_HANGUP))) {
 +						/* There's a problem, hang them up*/
-+						if (option_verbose > 1) 
++						if (option_verbose > 1)
 +							ast_verbose(VERBOSE_PREFIX_2 "%s logged out of autoanswer app\n", pu->chan->name);
 +						manager_event(EVENT_FLAG_CALL, "AutoanswerLogout",
 +                            			    "Channel: %s\r\n"
@@ -415,7 +415,7 @@
 +							ast_log(LOG_WARNING, "Whoa, no %s context?\n", pu->exten);
 +						}
 +						/* And take them out of the parking lot */
-+						if (pl) 
++						if (pl)
 +							pl->next = pu->next;
 +						else
 +							aalot = pu->next;
@@ -518,7 +518,7 @@
 +
 +	if (peer) {
 +		ast_moh_stop(peer);
-+		/* Play a courtesy beep in the callED channel to prefix the bridge connecting */	
++		/* Play a courtesy beep in the callED channel to prefix the bridge connecting */
 +		if (!ast_strlen_zero(courtesytone)) {
 +			if (!ast_streamfile(peer, courtesytone, peer->language)) {
 +				if (ast_waitstream(peer, "") < 0) {
@@ -528,7 +528,7 @@
 +				}
 +			}
 +		}
-+ 
++
 +		res = ast_channel_make_compatible(chan, peer);
 +		if (res < 0) {
 +			ast_log(LOG_WARNING, "Could not make channels %s and %s compatible for bridge\n", chan->name, peer->name);
@@ -537,7 +537,7 @@
 +		}
 +		/* This runs sorta backwards, since we give the incoming channel control, as if it
 +		   were the person called. */
-+		if (option_verbose > 2) 
++		if (option_verbose > 2)
 +			ast_verbose(VERBOSE_PREFIX_3 "Channel %s autoanswered  %s\n", peer->name, chan->name);
 +		manager_event(EVENT_FLAG_CALL, "Autoanswer",
 +                    "Channel: %s\r\n"
@@ -558,14 +558,14 @@
 +		config.warning_sound=NULL;
 +		res = ast_bridge_call(chan,peer,&config);
 +
-+		if (option_verbose > 2) 
++		if (option_verbose > 2)
 +			ast_verbose(VERBOSE_PREFIX_3 "returning from bridge %s\n", peer->name);
 +			/* relogin */
 +		snprintf(datastring, sizeof(datastring) - 1, "%s|%s", aacontext, aaexten);
 +		ast_autoanswer_login(peer, datastring);
 +		return res;
 +	} else {
-+		if (option_verbose > 2) 
++		if (option_verbose > 2)
 +			ast_verbose(VERBOSE_PREFIX_3 "Nobody logged in for autoanswer %s@%s\n", aaexten, aacontext);
 +		res = -1;
 +	}

Modified: asterisk/trunk/debian/patches/bristuff/feature-holdedcalls
URL: http://svn.debian.org/wsvn/pkg-voip/asterisk/trunk/debian/patches/bristuff/feature-holdedcalls?rev=5792&op=diff
==============================================================================
--- asterisk/trunk/debian/patches/bristuff/feature-holdedcalls (original)
+++ asterisk/trunk/debian/patches/bristuff/feature-holdedcalls Sun May 25 20:30:23 2008
@@ -85,7 +85,7 @@
 +		memset(pu, 0, sizeof(pu));
 +		ast_mutex_lock(&holding_lock);
 +		chan->appl = "Holded Call";
-+		chan->data = NULL; 
++		chan->data = NULL;
 +
 +		pu->chan = chan;
 +		strncpy(pu->uniqueid, chan->uniqueid, sizeof(pu->uniqueid));
@@ -169,7 +169,7 @@
 +		}
 +		/* This runs sorta backwards, since we give the incoming channel control, as if it
 +		   were the person called. */
-+		if (option_verbose > 2) 
++		if (option_verbose > 2)
 +			ast_verbose(VERBOSE_PREFIX_3 "Channel %s connected to holded call %s\n", chan->name, peer->name);
 +
 +		memset(&config,0,sizeof(struct ast_bridge_config));
@@ -207,7 +207,7 @@
 +
 +	if (peer) {
 +		res=0;
-+		if (option_verbose > 2) 
++		if (option_verbose > 2)
 +			ast_verbose(VERBOSE_PREFIX_3 "Channel %s removed from hold.\n", peer->name);
 +		ast_mutex_unlock(&peer->lock);
 +		ast_hangup(peer);
@@ -230,7 +230,7 @@
 +			if (pl)
 +				pl->next = pu->next;
 +			else
-+				holdlist = pu->next; 
++				holdlist = pu->next;
 +			break;
 +		}
 +		pl = pu;
@@ -242,12 +242,12 @@
 +		free(pu);
 +		if (peer) {
 +		    res=0;
-+		    if (option_verbose > 2) 
++		    if (option_verbose > 2)
 +			ast_verbose(VERBOSE_PREFIX_3 "Channel %s removed from hold.\n", peer->name);
 + 		    ast_moh_stop(peer);
 +		    return peer;
 + 		} else {
-+		    if (option_verbose > 2) 
++		    if (option_verbose > 2)
 +			ast_verbose(VERBOSE_PREFIX_3 "Could not find channel with uniqueid %s.\n", uniqueid);
 +		    return NULL;
 +		}
@@ -291,13 +291,13 @@
 +						f = ast_read(pu->chan);
 +						if (!f || ((f->frametype == AST_FRAME_CONTROL) && (f->subclass ==  AST_CONTROL_HANGUP))) {
 +							/* There's a problem, hang them up*/
-+							if (option_verbose > 1) 
++							if (option_verbose > 1)
 +								ast_verbose(VERBOSE_PREFIX_2 "%s got tired of being onhold\n", pu->chan->name);
 +							ast_hangup(pu->chan);
 +							/* find the corresponding channel and hang them up too! */
 +							/* but only if it is not bridged yet! */
 +							/* And take them out of the parking lot */
-+							if (pl) 
++							if (pl)
 +								pl->next = pu->next;
 +							else
 +								holdlist = pu->next;

Modified: asterisk/trunk/debian/patches/bristuff/misc-app-devstate
URL: http://svn.debian.org/wsvn/pkg-voip/asterisk/trunk/debian/patches/bristuff/misc-app-devstate?rev=5792&op=diff
==============================================================================
--- asterisk/trunk/debian/patches/bristuff/misc-app-devstate (original)
+++ asterisk/trunk/debian/patches/bristuff/misc-app-devstate Sun May 25 20:30:23 2008
@@ -3,7 +3,7 @@
 @@ -0,0 +1,202 @@
 +/*
 + * Devstate application
-+ * 
++ *
 + * Since we like the snom leds so much, a little app to
 + * light the lights on the snom on demand ....
 + *
@@ -41,8 +41,8 @@
 +
 +static char descrip[] = " Devstate(device|state):  Generate a device state change event given the input parameters. Returns 0. State values match the asterisk device states. They are 0 = unknown, 1 = not inuse, 2 = inuse, 3 = busy, 4 = invalid, 5 = unavailable, 6 = ringing\n";
 +
-+static char devstate_cli_usage[] = 
-+"Usage: devstate device state\n" 
++static char devstate_cli_usage[] =
++"Usage: devstate device state\n"
 +"       Generate a device state change event given the input parameters.\n Mainly used for lighting the LEDs on the snoms.\n";
 +
 +static int devstate_cli(int fd, int argc, char *argv[]);
@@ -141,7 +141,7 @@
 +	.setoption = NULL,
 +};
 +
-+static char mandescr_devstate[] = 
++static char mandescr_devstate[] =
 +"Description: Put a value into astdb\n"
 +"Variables: \n"
 +"	Family: ...\n"
@@ -184,7 +184,7 @@
 +        ast_log(LOG_DEBUG, "Unable to register channel class %s\n", type);
 +        return -1;
 +    }
-+    ast_cli_register(&cli_dev_state);  
++    ast_cli_register(&cli_dev_state);
 +    ast_manager_register2( "Devstate", EVENT_FLAG_CALL, action_devstate, "Change a device state", mandescr_devstate );
 +    return ast_register_application(app, devstate_exec, synopsis, descrip);
 +}
@@ -197,7 +197,7 @@
 +    ast_manager_unregister( "Devstate");
 +    ast_cli_unregister(&cli_dev_state);
 +    res = ast_unregister_application(app);
-+    ast_channel_unregister(&devstate_tech);    
++    ast_channel_unregister(&devstate_tech);
 +    return res;
 +}
 +

Modified: asterisk/trunk/debian/patches/bristuff/uniqueid-10-channel-ops-uniqueid
URL: http://svn.debian.org/wsvn/pkg-voip/asterisk/trunk/debian/patches/bristuff/uniqueid-10-channel-ops-uniqueid?rev=5792&op=diff
==============================================================================
--- asterisk/trunk/debian/patches/bristuff/uniqueid-10-channel-ops-uniqueid (original)
+++ asterisk/trunk/debian/patches/bristuff/uniqueid-10-channel-ops-uniqueid Sun May 25 20:30:23 2008
@@ -6,13 +6,13 @@
   */
  struct ast_channel *ast_request(const char *type, int format, void *data, int *status);
  
-+/*! \brief Requests a channel 
++/*! \brief Requests a channel
 + * \param type type of channel to request
 + * \param format requested channel format (codec)
 + * \param data data to pass to the channel requester
 + * \param status status
 + * \param uniqueid uniqueid
-+ * Request a channel of a given type, with data as optional information used 
++ * Request a channel of a given type, with data as optional information used
 + * by the low level module. Sets the channels uniqueid to 'uniqueid'.
 + * \return Returns an ast_channel on success, NULL on failure.
 + */
@@ -59,7 +59,7 @@
  				 */
  			}
 -			if (name) { /* want match by name */
-+			if (uniqueid) { 
++			if (uniqueid) {
 +			    if (!strcasecmp(c->uniqueid, uniqueid))
 +				break;
 +			} else if (name) { /* want match by name */

Modified: asterisk/trunk/debian/patches/bristuff/uniqueid-30-app-chanspy
URL: http://svn.debian.org/wsvn/pkg-voip/asterisk/trunk/debian/patches/bristuff/uniqueid-30-app-chanspy?rev=5792&op=diff
==============================================================================
--- asterisk/trunk/debian/patches/bristuff/uniqueid-30-app-chanspy (original)
+++ asterisk/trunk/debian/patches/bristuff/uniqueid-30-app-chanspy Sun May 25 20:30:23 2008
@@ -12,7 +12,7 @@
  "                    channel.\n"
  ;
  
-+static const char *desc_uniqueid = 
++static const char *desc_uniqueid =
 +"  ChanSpyChan(uniqueid[|options]): This application is used to listen to the\n"
 +"audio from an Asterisk channel. This includes the audio coming in and\n"
 +"out of the channel being spied on. The 'uniqueid' parameter has to be specified,\n"
@@ -137,7 +137,7 @@
 +
 +	if (options) {
 +		char *opts[OPT_ARG_ARRAY_SIZE];
-+		
++
 +		ast_app_parse_options(spy_opts, &flags, opts, options);
 +		if (ast_test_flag(&flags, OPTION_GROUP))
 +			mygroup = opts[OPT_ARG_GROUP];

Modified: asterisk/trunk/debian/patches/bristuff/uniqueid-40-manager
URL: http://svn.debian.org/wsvn/pkg-voip/asterisk/trunk/debian/patches/bristuff/uniqueid-40-manager?rev=5792&op=diff
==============================================================================
--- asterisk/trunk/debian/patches/bristuff/uniqueid-40-manager (original)
+++ asterisk/trunk/debian/patches/bristuff/uniqueid-40-manager Sun May 25 20:30:23 2008
@@ -28,7 +28,7 @@
 +	} else {
 +	    if (!ast_strlen_zero(name))
 +		c = ast_get_channel_by_name_locked(name);
-+	}	
++	}
 +
  	if (!c) {
  		astman_send_error(s, m, "No such channel");

Modified: asterisk/trunk/debian/patches/bristuff/xagi
URL: http://svn.debian.org/wsvn/pkg-voip/asterisk/trunk/debian/patches/bristuff/xagi?rev=5792&op=diff
==============================================================================
--- asterisk/trunk/debian/patches/bristuff/xagi (original)
+++ asterisk/trunk/debian/patches/bristuff/xagi Sun May 25 20:30:23 2008
@@ -82,7 +82,7 @@
 +			return AGI_RESULT_FAILURE;
 +		}
 +		res = fcntl(audio2[0], F_GETFL);
-+		if (res > -1) 
++		if (res > -1)
 +			res = fcntl(audio2[0], F_SETFL, res | O_NONBLOCK);
 +		if (res < 0) {
 +			ast_log(LOG_WARNING, "unable to set audio pipe parameters: %s\n", strerror(errno));
@@ -117,7 +117,7 @@
  
  		/* Close everything but stdin/out/error */
 -		for (x=STDERR_FILENO + 2;x<1024;x++) 
-+		for (x=STDERR_FILENO + 3;x<1024;x++) 
++		for (x=STDERR_FILENO + 3;x<1024;x++)
  			close(x);
  
  		/* Execute script */
@@ -305,8 +305,8 @@
 +/*
 + * Asterisk -- A telephony toolkit for Linux.
 + *
-+ * XAGI sample script 
-+ * 
++ * XAGI sample script
++ *
 + * Copyright (C) 2005 Junghanns.NET GmbH
 + * Klaus-Peter Junghanns <kpj at junghanns.net>
 + *
@@ -355,7 +355,7 @@
 +
 +		/* Load into normal environment */
 +		setenv(buf, val, 1);
-+		
++
 +	}
 +	/* Never reached */
 +	return 0;
@@ -430,7 +430,7 @@
 +			/* drop it, like it's hot */
 +		}
 +	}
-+		
++
 +}
 +
 +static char *run_command(char *command)

Modified: asterisk/trunk/debian/patches/bristuff/zapata-bri+euroisdn
URL: http://svn.debian.org/wsvn/pkg-voip/asterisk/trunk/debian/patches/bristuff/zapata-bri%2Beuroisdn?rev=5792&op=diff
==============================================================================
--- asterisk/trunk/debian/patches/bristuff/zapata-bri+euroisdn (original)
+++ asterisk/trunk/debian/patches/bristuff/zapata-bri+euroisdn Sun May 25 20:30:23 2008
@@ -508,7 +508,7 @@
 +#ifdef HAVE_PRI
 +		    if (i->pri) {
 +			if ((i->pri->nodetype == BRI_CPE_PTMP) || (i->pri->nodetype == BRI_CPE)) {
-+			/* dont annoy BRI TE mode users with layer2layer alarms */
++			    /* dont annoy BRI TE mode users with layer2layer alarms */
 +			} else {
 +#endif
  			ast_log(LOG_NOTICE, "Alarm cleared on channel %d\n", i->channel);
@@ -530,7 +530,7 @@
 +#ifdef HAVE_PRI
 +		    if (i->pri) {
 +			if ((i->pri->nodetype == BRI_CPE_PTMP) || (i->pri->nodetype == BRI_CPE)) {
-+				/* dont annoy BRI TE mode users with layer2layer alarms */
++			    /* dont annoy BRI TE mode users with layer2layer alarms */
 +			} else {
 +#endif
 +			    const char *alarm_str = alarm2str(res);
@@ -674,40 +674,40 @@
  
  				/* Copy any DSP that may be present */
 -				new->dsp = old->dsp;
-+  				new->dsp = old->dsp;
++				new->dsp = old->dsp;
  				new->dsp_features = old->dsp_features;
  				old->dsp = NULL;
  				old->dsp_features = 0;
 -			}
 +
 +				/* Copy faxhandled/digial, alreadyhungup */
-+  				new->faxhandled = old->faxhandled;
++				new->faxhandled = old->faxhandled;
 +				new->digital = old->digital;
 +				new->alreadyhungup = old->alreadyhungup;
 +
 +				/* Copy law, gains, etc */
-+  				    new->law = old->law;
++				new->law = old->law;
 +				if (ioctl(new->subs[SUB_REAL].zfd, ZT_AUDIOMODE, &new->law) == -1)
 +				    ast_log(LOG_WARNING, "Unable to set audio mode on channel %d to %d\n", new->channel, new->law);
 +				res = zt_setlaw(new->subs[SUB_REAL].zfd, new->law);
-+  				    if (res < 0)
-+  					ast_log(LOG_WARNING, "Unable to set law on channel %d\n", new->channel);
-+				    if (!new->digital) {
++				if (res < 0)
++				    ast_log(LOG_WARNING, "Unable to set law on channel %d\n", new->channel);
++				if (!new->digital) {
 +				    res = set_actual_gain(new->subs[SUB_REAL].zfd, 0, new->rxgain, new->txgain, new->law);
-+  				    } else {
++				} else {
 +				    res = set_actual_gain(new->subs[SUB_REAL].zfd, 0, 0, 0, new->law);
-+				    }
-+				    if (res < 0)
-+  					ast_log(LOG_WARNING, "Unable to set gains on channel %d\n", new->channel);
++				}
++				if (res < 0)
++				    ast_log(LOG_WARNING, "Unable to set gains on channel %d\n", new->channel);
 +
 +				/* Shutdown old channel */
-+  				    zt_confmute(old, 0);
-+  				    update_conf(old);
-+  				    reset_conf(old);
-+  				    restore_gains(old);
-+  				    zt_disable_ec(old);
-+  				    zt_setlinear(old->subs[SUB_REAL].zfd, 0);
-+  				}
++				zt_confmute(old, 0);
++				update_conf(old);
++				reset_conf(old);
++				restore_gains(old);
++				zt_disable_ec(old);
++				zt_setlinear(old->subs[SUB_REAL].zfd, 0);
++			}
  			return principle;
  		}
  	}
@@ -912,59 +912,34 @@
  		if (e) {
  			if (pri->debug)
  				pri_dump_event(pri->dchans[which], e);
-@@ -8560,13 +8732,13 @@ static void *pri_dchannel(void *vpri)
- 			if (e->e != PRI_EVENT_DCHAN_DOWN) {
- 				if (!(pri->dchanavail[which] & DCHAN_UP)) {
- 					if (option_verbose > 1) 
--						ast_verbose(VERBOSE_PREFIX_2 "%s D-Channel on span %d up\n", pri_order(which), pri->span);
--				}
-+							ast_verbose(VERBOSE_PREFIX_2 "%s D-Channel on span %d up\n", pri_order(which), pri->span);
-+					}
- 				pri->dchanavail[which] |= DCHAN_UP;
- 			} else {
- 				if (pri->dchanavail[which] & DCHAN_UP) {
- 					if (option_verbose > 1) 
--						ast_verbose(VERBOSE_PREFIX_2 "%s D-Channel on span %d down\n", pri_order(which), pri->span);
-+							ast_verbose(VERBOSE_PREFIX_2 "%s D-Channel on span %d down\n", pri_order(which), pri->span);
- 				}
- 				pri->dchanavail[which] &= ~DCHAN_UP;
- 			}
 @@ -8577,41 +8749,60 @@ static void *pri_dchannel(void *vpri)
  
  			switch (e->e) {
  			case PRI_EVENT_DCHAN_UP:
-+  				if (pri->nodetype == BRI_NETWORK_PTMP) {
-+ 				    if (option_verbose > 3)
-+ 					ast_verbose(VERBOSE_PREFIX_2 "%s D-Channel on span %d up for TEI %d\n", pri_order(which), pri->span, e->gen.tei);
++				if (pri->nodetype == BRI_NETWORK_PTMP) {
++				    if (option_verbose > 3)
++					ast_verbose(VERBOSE_PREFIX_2 "%s D-Channel on span %d up for TEI %d\n", pri_order(which), pri->span, e->gen.tei);
 +				} else if (pri->nodetype == BRI_CPE_PTMP) {
-+ 				    if (option_verbose > 3)
-+  					    ast_verbose(VERBOSE_PREFIX_2 "%s D-Channel on span %d up\n", pri_order(which), pri->span);
-+  				} else {
-+  				    if (option_verbose > 1)
-+  					    ast_verbose(VERBOSE_PREFIX_2 "%s D-Channel on span %d up\n", pri_order(which), pri->span);
-+  				}
++				    if (option_verbose > 3)
++					    ast_verbose(VERBOSE_PREFIX_2 "%s D-Channel on span %d up\n", pri_order(which), pri->span);
++				} else {
++				    if (option_verbose > 1)
++					    ast_verbose(VERBOSE_PREFIX_2 "%s D-Channel on span %d up\n", pri_order(which), pri->span);
++				}
 +
  				if (!pri->pri) pri_find_dchan(pri);
  
--				/* Note presense of D-channel */
--				time(&pri->lastreset);
-+				    /* Note presense of D-channel */
-+				    time(&pri->lastreset);
- 
--				/* Restart in 5 seconds */
--				if (pri->resetinterval > -1) {
-+				    /* Restart in 5 seconds */
-+				    if (pri->resetinterval > -1) {
+ 				/* Note presense of D-channel */
+ 				time(&pri->lastreset);
+ 
+ 				/* Restart in 5 seconds */
+ 				if (pri->resetinterval > -1) {
  					pri->lastreset -= pri->resetinterval;
  					pri->lastreset += 5;
--				}
--				pri->resetting = 0;
--				/* Take the channels from inalarm condition */
--				for (i = 0; i < pri->numchans; i++)
-+				    }
-+				    pri->resetting = 0;
-+				    /* Take the channels from inalarm condition */
-+				    for (i = 0; i < pri->numchans; i++)
+ 				}
+ 				pri->resetting = 0;
+ 				/* Take the channels from inalarm condition */
+ 				for (i = 0; i < pri->numchans; i++)
  					if (pri->pvts[i]) {
  						pri->pvts[i]->inalarm = 0;
  					}
@@ -972,14 +947,14 @@
  			case PRI_EVENT_DCHAN_DOWN:
 -				pri_find_dchan(pri);
 -				if (!pri_is_up(pri)) {
-+  				if (pri->nodetype == BRI_NETWORK_PTMP) {
++				if (pri->nodetype == BRI_NETWORK_PTMP) {
 +  				    if (option_verbose > 3)
 +  					ast_verbose(VERBOSE_PREFIX_2 "%s D-Channel on span %d down for TEI %d\n", pri_order(which), pri->span, e->gen.tei);
 +  				    // PTMP BRIs have N dchans, handled by libpri
 +  				    if (e->gen.tei == 0) break;
-+  				    }
-+				    pri_find_dchan(pri);
-+				    if (!pri_is_up(pri)) {
++				}
++				pri_find_dchan(pri);
++				if (!pri_is_up(pri)) {
  					pri->resetting = 0;
  					/* Hangup active channels and put them in alarm mode */
  					for (i = 0; i < pri->numchans; i++) {

Modified: asterisk/trunk/debian/patches/bristuff/zapata-gsm
URL: http://svn.debian.org/wsvn/pkg-voip/asterisk/trunk/debian/patches/bristuff/zapata-gsm?rev=5792&op=diff
==============================================================================
--- asterisk/trunk/debian/patches/bristuff/zapata-gsm (original)
+++ asterisk/trunk/debian/patches/bristuff/zapata-gsm Sun May 25 20:30:23 2008
@@ -363,7 +363,7 @@
 +		      	"Length: %d\r\n"
 +		  	"Text: %s\r\n"
 +		  	"PDU: %s\r\n",
-+			gsm->span, 
++			gsm->span,
 +			e->sm_received.sender,
 +			e->sm_received.smsc,
 +			e->sm_received.len,
@@ -391,7 +391,7 @@
 +	}
 +	gsm_set_debug(gsm->modul, GSM_DEBUG_NONE);
 +	for (;;) {
-+		
++
 +		/* Run the D-Channel */
 +		FD_ZERO(&rfds);
 +		FD_ZERO(&efds);
@@ -422,7 +422,7 @@
 +		} else if (errno == ELAST) {
 +			res = ioctl(gsm->fd, ZT_GETEVENT, &x);
 +			printf("Got Zaptel event: %d\n", x);
-+		} else if (errno != EINTR) 
++		} else if (errno != EINTR)
 +			fprintf(stderr, "Error (%d) on select: %s\n", ELAST, strerror(errno));
 +
 +		if (!e) {
@@ -521,7 +521,7 @@
 +	    }
 +	    pvt = pvt->next;
 +	}
-+	
++
 +	ast_cli(fd, "No GSM running on channel %d\n", channel);
 +	return RESULT_SUCCESS;
 +}
@@ -550,15 +550,15 @@
 + return handle_gsm_debug_helper(fd, channel, GSM_DEBUG_NONE);
 +}
 +
-+static char zap_reset_help[] = 
++static char zap_reset_help[] =
 +	"Usage: zap reset span <span>\n"
 +	"       Reset/Restart a zaptel span\n";
 +
-+static char gsm_debug_help[] = 
++static char gsm_debug_help[] =
 +	"Usage: gsm debug channel <channel>\n"
 +	"       Enables debugging on a given GSM channel\n";
-+	
-+static char gsm_no_debug_help[] = 
++
++static char gsm_no_debug_help[] =
 +	"Usage: gsm no debug channel <channel>\n"
 +	"       Disables debugging on a given GSM channel\n";
 +
@@ -573,7 +573,7 @@
 +
 +
 +
-+static char gsm_send_pdu_help[] = 
++static char gsm_send_pdu_help[] =
 +	"Usage: gsm send pdu <channel> <pdu>\n"
 +	"       Sends a PDU on a GSM channel\n";
 +
@@ -607,7 +607,7 @@
 +	    }
 +	    pvt = pvt->next;
 +	}
-+	
++
 +	return RESULT_SUCCESS;
 +}
 +
@@ -615,7 +615,7 @@
 +	{ "gsm", "send", "pdu", NULL }, handle_gsm_send_pdu, "Sends a SM on a GSM channel", gsm_send_pdu_help, complete_span_4 };
 +
 +
-+static char gsm_send_sms_help[] = 
++static char gsm_send_sms_help[] =
 +	"Usage: gsm send sms <channel> <destination> <message>\n"
 +	"       Sends a SM on a GSM channel\n";
 +
@@ -648,7 +648,7 @@
 +	    }
 +	    pvt = pvt->next;
 +	}
-+	
++
 +	return RESULT_SUCCESS;
 +}
 +
@@ -656,16 +656,16 @@
 +     struct zt_pvt *pvt = NULL;
 +     char *c = NULL;
 +     pvt = chan->tech_pvt;
-+     
++
 +     if (!pvt) return -1;
-+     
++
 +     /* parse dialstring */
 +     c = strrchr(dest, '/');
 +     if (c)
 + 	c++;
 +     else
 + 	c = (char *)dest;
-+ 
++
 +     ast_mutex_lock(&pvt->lock);
 + 	if (ispdu) {
 +     	    gsm_sms_send_pdu(pvt->gsm.modul, (char *)text);
@@ -676,11 +676,11 @@
 +     gsm_wait(pvt->gsm.modul);
 +     return 0;
 +}
-+ 
++
 +static struct ast_cli_entry gsm_send_sms = {
 +	{ "gsm", "send", "sms", NULL }, handle_gsm_send_sms, "Sends a SM on a GSM channel", gsm_send_sms_help, complete_span_4 };
 +
-+static char gsm_show_status_help[] = 
++static char gsm_show_status_help[] =
 +	"Usage: gsm show status <channel>>\n"
 +	"       Displays status information about the GSM channel.\n";
 +
@@ -712,7 +712,7 @@
 +	    }
 +	    pvt = pvt->next;
 +	}
-+	
++
 +	return RESULT_SUCCESS;
 +}
 +
@@ -745,7 +745,7 @@
 +				} else if (!strcasecmp(v->value, "gsm")) {
 +					confp->chan.sig = SIG_GSM;
 +					confp->chan.radio = 0;
-+#endif				
++#endif
  				} else {
  					ast_log(LOG_ERROR, "Unknown signalling method '%s'\n", v->value);
  				}
@@ -797,7 +797,7 @@
 + if (!p) return -1;
 + if (!p->pri) return -1;
 +	    if (strlen(text)) {
-+		if (p->pri) {		
++		if (p->pri) {
 +		    if (!pri_grab(p, p->pri)) {
 +		//	ast_log(LOG_NOTICE, "Sending Display IE  '%s'\n", text);
 +			pri_information_display(p->pri->pri,p->call,(char *)text);
@@ -824,7 +824,7 @@
 +}
 +
 +static int zt_sendmessage(struct ast_channel *c, const char *dest, const char *text, int ispdu) {
-+ struct zt_pvt *p = c->tech_pvt;
++struct zt_pvt *p = c->tech_pvt;
 + if (!p) return -1;
 + if (p->sig == SIG_PRI) {
 +#ifdef HAVE_PRI




More information about the Pkg-voip-commits mailing list