Browse code

- export param types adjusted to PARAM_STR/STRING & PARAM_INT - removed corresponding obsolete strlen(str_param) in init

Tomas Mandys authored on 08/01/2006 22:43:14
Showing 5 changed files
... ...
@@ -99,7 +99,7 @@ include Makefile.defs
99 99
 NAME=$(MAIN_NAME)
100 100
 
101 101
 #export relevant variables to the sub-makes
102
-export DEFS PROFILE CC LD MKDEP MKTAGS CFLAGS LDFLAGS MOD_CFLAGS MOD_LDFLAGS 
102
+export DEFS PROFILE CC LD MKDEP MKTAGS CFLAGS LDFLAGS INCLUDES MOD_CFLAGS MOD_LDFLAGS 
103 103
 export LIBS
104 104
 export LEX YACC YACC_FLAGS
105 105
 export PREFIX LOCALBASE
... ...
@@ -17,7 +17,8 @@ override modules=
17 17
 override static_modules=
18 18
 override static_modules_path=
19 19
 
20
-INCLUDES += -I$(COREPATH)
20
+# should be set in Makefile of apart module
21
+# INCLUDES += -I$(COREPATH)
21 22
 
22 23
 ifeq ($(MAKELEVEL), 0)
23 24
 # make called directly in the module dir!
... ...
@@ -22,8 +22,8 @@
22 22
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
23 23
  * GNU General Public License for more details.
24 24
  *
25
- * You should have received a copy of the GNU General Public License 
26
- * along with this program; if not, write to the Free Software 
25
+ * You should have received a copy of the GNU General Public License
26
+ * along with this program; if not, write to the Free Software
27 27
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
28 28
  *
29 29
  * History:
... ...
@@ -35,7 +35,7 @@
35 35
  *  2003-04-05  s/reply_route/failure_route, onreply_route introduced (jiri)
36 36
  *  2003-04-12  added force_rport, chdir and wdir (andrei)
37 37
  *  2003-04-22  strip_tail added (jiri)
38
- *  2003-07-03  tls* (disable, certificate, private_key, ca_list, verify, 
38
+ *  2003-07-03  tls* (disable, certificate, private_key, ca_list, verify,
39 39
  *               require_certificate added (andrei)
40 40
  *  2003-07-06  more tls config. vars added: tls_method, tls_port_no (andrei)
41 41
  *  2003-10-02  added {,set_}advertised_{address,port} (andrei)
... ...
@@ -89,7 +89,7 @@
89 89
 		int left;
90 90
 	};
91 91
 
92
-	
92
+
93 93
 	static int comment_nest=0;
94 94
 	static int state=0;
95 95
 	static struct str_buf s_buf;
... ...
@@ -351,7 +351,7 @@ EAT_ABLE	[\ \t\b\r]
351 351
 <INITIAL>{PREFIX}	{ count(); yylval.strval=yytext; return PREFIX; }
352 352
 <INITIAL>{STRIP}	{ count(); yylval.strval=yytext; return STRIP; }
353 353
 <INITIAL>{STRIP_TAIL}	{ count(); yylval.strval=yytext; return STRIP_TAIL; }
354
-<INITIAL>{APPEND_BRANCH}	{ count(); yylval.strval=yytext; 
354
+<INITIAL>{APPEND_BRANCH}	{ count(); yylval.strval=yytext;
355 355
 								return APPEND_BRANCH; }
356 356
 <INITIAL>{FORCE_RPORT}	{ count(); yylval.strval=yytext; return FORCE_RPORT; }
357 357
 <INITIAL>{FORCE_TCP_ALIAS}	{ count(); yylval.strval=yytext;
... ...
@@ -441,11 +441,11 @@ EAT_ABLE	[\ \t\b\r]
441 441
 <INITIAL>{TLS_VERIFY}	{ count(); yylval.strval=yytext; return TLS_VERIFY; }
442 442
 <INITIAL>{TLS_REQUIRE_CERTIFICATE}	{ count(); yylval.strval=yytext;
443 443
 										return TLS_REQUIRE_CERTIFICATE; }
444
-<INITIAL>{TLS_CERTIFICATE}	{ count(); yylval.strval=yytext; 
444
+<INITIAL>{TLS_CERTIFICATE}	{ count(); yylval.strval=yytext;
445 445
 										return TLS_CERTIFICATE; }
446
-<INITIAL>{TLS_PRIVATE_KEY}	{ count(); yylval.strval=yytext; 
446
+<INITIAL>{TLS_PRIVATE_KEY}	{ count(); yylval.strval=yytext;
447 447
 										return TLS_PRIVATE_KEY; }
448
-<INITIAL>{TLS_CA_LIST}	{ count(); yylval.strval=yytext; 
448
+<INITIAL>{TLS_CA_LIST}	{ count(); yylval.strval=yytext;
449 449
 										return TLS_CA_LIST; }
450 450
 <INITIAL>{TLS_HANDSHAKE_TIMEOUT}	{ count(); yylval.strval=yytext;
451 451
 										return TLS_HANDSHAKE_TIMEOUT; }
... ...
@@ -488,10 +488,10 @@ EAT_ABLE	[\ \t\b\r]
488 488
 <INITIAL>{MINUS}	{ count(); return MINUS; }
489 489
 
490 490
 <INITIAL>{SELECT_MARK}  { count(); state = SELECT_S; BEGIN(SELECT); return SELECT_MARK; }
491
-<SELECT>{ID}		{ count(); addstr(&s_buf, yytext, yyleng); 
491
+<SELECT>{ID}		{ count(); addstr(&s_buf, yytext, yyleng);
492 492
                           yylval.strval=s_buf.s;
493 493
                           memset(&s_buf, 0, sizeof(s_buf));
494
-                          return ID; 
494
+                          return ID;
495 495
                         }
496 496
 <SELECT>{DOT}           { count(); return DOT; }
497 497
 <SELECT>{LBRACK}        { count(); return LBRACK; }
... ...
@@ -514,12 +514,12 @@ EAT_ABLE	[\ \t\b\r]
514 514
 <ATTR>{RBRACK}          { count(); return RBRACK; }
515 515
 <ATTR>{STAR}		{ count(); return STAR; }
516 516
 <ATTR>{DECNUMBER}	{ count(); yylval.intval=atoi(yytext);return NUMBER; }
517
-<ATTR>{ID}		{ count(); addstr(&s_buf, yytext, yyleng); 
517
+<ATTR>{ID}		{ count(); addstr(&s_buf, yytext, yyleng);
518 518
                            yylval.strval=s_buf.s;
519 519
 			   memset(&s_buf, 0, sizeof(s_buf));
520 520
                            state = INITIAL_S;
521 521
                            BEGIN(INITIAL);
522
-			   return ID; 
522
+			   return ID;
523 523
                         }
524 524
 
525 525
 <INITIAL>{IPV6ADDR}		{ count(); yylval.strval=yytext; return IPV6ADDR; }
... ...
@@ -567,14 +567,14 @@ EAT_ABLE	[\ \t\b\r]
567 567
 <INITIAL>{TICK} { count(); state=STRING_S; BEGIN(STRING2); }
568 568
 
569 569
 
570
-<STRING1>{QUOTES} { count(); state=INITIAL_S; BEGIN(INITIAL); 
570
+<STRING1>{QUOTES} { count(); state=INITIAL_S; BEGIN(INITIAL);
571 571
 						yytext[yyleng-1]=0; yyleng--;
572 572
 						addstr(&s_buf, yytext, yyleng);
573 573
 						yylval.strval=s_buf.s;
574 574
 						memset(&s_buf, 0, sizeof(s_buf));
575 575
 						return STRING;
576 576
 					}
577
-<STRING2>{TICK}  { count(); state=INITIAL_S; BEGIN(INITIAL); 
577
+<STRING2>{TICK}  { count(); state=INITIAL_S; BEGIN(INITIAL);
578 578
 						yytext[yyleng-1]=0; yyleng--;
579 579
 						addstr(&s_buf, yytext, yyleng);
580 580
 						yylval.strval=s_buf.s;
... ...
@@ -588,12 +588,12 @@ EAT_ABLE	[\ \t\b\r]
588 588
 <STRING1>\\a		{ count(); addchar(&s_buf, '\a'); }
589 589
 <STRING1>\\t		{ count(); addchar(&s_buf, '\t'); }
590 590
 <STRING1>\\{QUOTES}	{ count(); addchar(&s_buf, '"');  }
591
-<STRING1>\\\\		{ count(); addchar(&s_buf, '\\'); } 
592
-<STRING1>\\x{HEX}{1,2}	{ count(); addchar(&s_buf, 
591
+<STRING1>\\\\		{ count(); addchar(&s_buf, '\\'); }
592
+<STRING1>\\x{HEX}{1,2}	{ count(); addchar(&s_buf,
593 593
 											(char)strtol(yytext+2, 0, 16)); }
594 594
  /* don't allow \[0-7]{1}, it will eat the backreferences from
595 595
     subst_uri if allowed (although everybody should use '' in subt_uri) */
596
-<STRING1>\\[0-7]{2,3}	{ count(); addchar(&s_buf, 
596
+<STRING1>\\[0-7]{2,3}	{ count(); addchar(&s_buf,
597 597
 											(char)strtol(yytext+1, 0, 8));  }
598 598
 <STRING1>\\{CR}		{ count(); } /* eat escaped CRs */
599 599
 <STRING1>.|{EAT_ABLE}|{CR}	{ addchar(&s_buf, *yytext); }
... ...
@@ -609,9 +609,9 @@ EAT_ABLE	[\ \t\b\r]
609 609
 								}
610 610
 <COMMENT>.|{EAT_ABLE}|{CR}				{ count(); };
611 611
 
612
-<INITIAL>{COM_LINE}.*{CR}	{ count(); } 
612
+<INITIAL>{COM_LINE}.*{CR}	{ count(); }
613 613
 
614
-<INITIAL>{ID}			{ count(); addstr(&s_buf, yytext, yyleng); 
614
+<INITIAL>{ID}			{ count(); addstr(&s_buf, yytext, yyleng);
615 615
 									yylval.strval=s_buf.s;
616 616
 									memset(&s_buf, 0, sizeof(s_buf));
617 617
 									return ID; }
... ...
@@ -619,7 +619,7 @@ EAT_ABLE	[\ \t\b\r]
619 619
 
620 620
 <<EOF>>							{
621 621
 									switch(state){
622
-										case STRING_S: 
622
+										case STRING_S:
623 623
 											LOG(L_CRIT, "ERROR: cfg. parser: unexpected EOF in"
624 624
 														" unclosed string\n");
625 625
 											if (s_buf.s){
... ...
@@ -639,7 +639,7 @@ EAT_ABLE	[\ \t\b\r]
639 639
 									}
640 640
 									return 0;
641 641
 								}
642
-			
642
+
643 643
 %%
644 644
 
645 645
 
... ...
@@ -655,7 +655,7 @@ static char* addstr(struct str_buf* dst_b, char* src, int len)
655 655
 	char *tmp;
656 656
 	unsigned size;
657 657
 	unsigned used;
658
-	
658
+
659 659
 	if (dst_b->left<(len+1)){
660 660
 		used=(unsigned)(dst_b->crt-dst_b->s);
661 661
 		size=used+len+1;
... ...
@@ -664,7 +664,7 @@ static char* addstr(struct str_buf* dst_b, char* src, int len)
664 664
 		tmp=pkg_malloc(size);
665 665
 		if (tmp==0) goto error;
666 666
 		if (dst_b->s){
667
-			memcpy(tmp, dst_b->s, used); 
667
+			memcpy(tmp, dst_b->s, used);
668 668
 			pkg_free(dst_b->s);
669 669
 		}
670 670
 		dst_b->s=tmp;
... ...
@@ -675,7 +675,7 @@ static char* addstr(struct str_buf* dst_b, char* src, int len)
675 675
 	dst_b->crt+=len;
676 676
 	*(dst_b->crt)=0;
677 677
 	dst_b->left-=len;
678
-	
678
+
679 679
 	return dst_b->s;
680 680
 error:
681 681
 	LOG(L_CRIT, "ERROR:lex:addstr: memory allocation error\n");
... ...
@@ -687,7 +687,7 @@ error:
687 687
 static void count()
688 688
 {
689 689
 	int i;
690
-	
690
+
691 691
 	startcolumn=column;
692 692
 	for (i=0; i<yyleng;i++){
693 693
 		if (yytext[i]=='\n'){
... ...
@@ -47,8 +47,8 @@
47 47
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
48 48
  * GNU General Public License for more details.
49 49
  *
50
- * You should have received a copy of the GNU General Public License 
51
- * along with this program; if not, write to the Free Software 
50
+ * You should have received a copy of the GNU General Public License
51
+ * along with this program; if not, write to the Free Software
52 52
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
53 53
  */
54 54
 /*
... ...
@@ -129,7 +129,7 @@ inline static int w_t_retransmit_reply(struct sip_msg* p_msg, char* foo,
129 129
 				char* bar );
130 130
 inline static int w_t_newtran(struct sip_msg* p_msg, char* foo, char* bar );
131 131
 inline static int w_t_relay( struct sip_msg  *p_msg , char *_foo, char *_bar);
132
-inline static int w_t_relay_to_udp( struct sip_msg  *p_msg , char *proxy, 
132
+inline static int w_t_relay_to_udp( struct sip_msg  *p_msg , char *proxy,
133 133
 				 char *);
134 134
 #ifdef USE_TCP
135 135
 inline static int w_t_relay_to_tcp( struct sip_msg  *p_msg , char *proxy,
... ...
@@ -139,19 +139,19 @@ inline static int w_t_relay_to_tcp( struct sip_msg  *p_msg , char *proxy,
139 139
 inline static int w_t_relay_to_tls( struct sip_msg  *p_msg , char *proxy,
140 140
 				char *);
141 141
 #endif
142
-inline static int w_t_replicate( struct sip_msg  *p_msg , 
142
+inline static int w_t_replicate( struct sip_msg  *p_msg ,
143 143
 				char *proxy, /* struct proxy_l *proxy expected */
144 144
 				char *_foo       /* nothing expected */ );
145
-inline static int w_t_replicate_udp( struct sip_msg  *p_msg , 
145
+inline static int w_t_replicate_udp( struct sip_msg  *p_msg ,
146 146
 				char *proxy, /* struct proxy_l *proxy expected */
147 147
 				char *_foo       /* nothing expected */ );
148 148
 #ifdef USE_TCP
149
-inline static int w_t_replicate_tcp( struct sip_msg  *p_msg , 
149
+inline static int w_t_replicate_tcp( struct sip_msg  *p_msg ,
150 150
 				char *proxy, /* struct proxy_l *proxy expected */
151 151
 				char *_foo       /* nothing expected */ );
152 152
 #endif
153 153
 #ifdef USE_TLS
154
-inline static int w_t_replicate_tls( struct sip_msg  *p_msg , 
154
+inline static int w_t_replicate_tls( struct sip_msg  *p_msg ,
155 155
 				char *proxy, /* struct proxy_l *proxy expected */
156 156
 				char *_foo       /* nothing expected */ );
157 157
 #endif
... ...
@@ -267,22 +267,22 @@ static cmd_export_t cmds[]={
267 267
 
268 268
 
269 269
 static param_export_t params[]={
270
-	{"ruri_matching",       INT_PARAM, &ruri_matching                        },
271
-	{"via1_matching",       INT_PARAM, &via1_matching                        },
272
-	{"fr_timer",            INT_PARAM, &fr_timeout                           },
273
-	{"fr_inv_timer",        INT_PARAM, &fr_inv_timeout                       },
274
-	{"wt_timer",            INT_PARAM, &wait_timeout                         },
275
-	{"delete_timer",        INT_PARAM, &delete_timeout                       },
276
-	{"retr_timer1",         INT_PARAM, &rt_t1_timeout                        },
277
-	{"retr_timer2"  ,       INT_PARAM, &rt_t2_timeout                        },
278
-	{"noisy_ctimer",        INT_PARAM, &noisy_ctimer                         },
279
-	{"uac_from",            STR_PARAM, &uac_from                             },
280
-	{"unix_tx_timeout",     INT_PARAM, &tm_unix_tx_timeout                   },
281
-	{"restart_fr_on_each_reply", INT_PARAM, &restart_fr_on_each_reply        },
282
-	{"fr_timer_avp",        STR_PARAM, &fr_timer_param                       },
283
-	{"fr_inv_timer_avp",    STR_PARAM, &fr_inv_timer_param                   },
284
-	{"tw_append",           STR_PARAM|USE_FUNC_PARAM, (void*)parse_tw_append },
285
-        {"pass_provisional_replies", INT_PARAM, &pass_provisional_replies        },
270
+	{"ruri_matching",       PARAM_INT, &ruri_matching                        },
271
+	{"via1_matching",       PARAM_INT, &via1_matching                        },
272
+	{"fr_timer",            PARAM_INT, &fr_timeout                           },
273
+	{"fr_inv_timer",        PARAM_INT, &fr_inv_timeout                       },
274
+	{"wt_timer",            PARAM_INT, &wait_timeout                         },
275
+	{"delete_timer",        PARAM_INT, &delete_timeout                       },
276
+	{"retr_timer1",         PARAM_INT, &rt_t1_timeout                        },
277
+	{"retr_timer2"  ,       PARAM_INT, &rt_t2_timeout                        },
278
+	{"noisy_ctimer",        PARAM_INT, &noisy_ctimer                         },
279
+	{"uac_from",            PARAM_STRING, &uac_from                          },
280
+	{"unix_tx_timeout",     PARAM_INT, &tm_unix_tx_timeout                   },
281
+	{"restart_fr_on_each_reply", PARAM_INT, &restart_fr_on_each_reply        },
282
+	{"fr_timer_avp",        PARAM_STRING, &fr_timer_param                    },
283
+	{"fr_inv_timer_avp",    PARAM_STRING, &fr_inv_timer_param                },
284
+	{"tw_append",           PARAM_STRING|PARAM_USE_FUNC, (void*)parse_tw_append },
285
+        {"pass_provisional_replies", PARAM_INT, &pass_provisional_replies        },
286 286
 	{0,0,0}
287 287
 };
288 288
 
... ...
@@ -298,7 +298,7 @@ struct module_exports exports= {
298 298
 	tm_rpc,    /* RPC methods */
299 299
 	/* ------------ exported variables ---------- */
300 300
 	params,
301
-	
301
+
302 302
 	mod_init, /* module initialization function */
303 303
 	(response_function) reply_received,
304 304
 	(destroy_function) tm_shutdown,
... ...
@@ -315,7 +315,7 @@ static int fixup_hostport2proxy(void** param, int param_no)
315 315
 	int err;
316 316
 	struct proxy_l *proxy;
317 317
 	str s;
318
-	
318
+
319 319
 	DBG("TM module: fixup_hostport2proxy(%s, %d)\n", (char*)*param, param_no);
320 320
 	if (param_no==1){
321 321
 		return 0;
... ...
@@ -354,7 +354,7 @@ static int w_t_unref( struct sip_msg *foo, void *bar)
354 354
 
355 355
 
356 356
 static int script_init( struct sip_msg *foo, void *bar)
357
-{   
357
+{
358 358
 	/* we primarily reset all private memory here to make sure
359 359
 	 * private values left over from previous message will
360 360
 	 * not be used again */
... ...
@@ -376,7 +376,7 @@ static int script_init( struct sip_msg *foo, void *bar)
376 376
 
377 377
 static int mod_init(void)
378 378
 {
379
-	DBG( "TM - (sizeof cell=%ld, sip_msg=%ld) initializing...\n", 
379
+	DBG( "TM - (sizeof cell=%ld, sip_msg=%ld) initializing...\n",
380 380
 			(long)sizeof(struct cell), (long)sizeof(struct sip_msg));
381 381
 	/* checking if we have sufficient bitmap capacity for given
382 382
 	   maximum number of  branches */
... ...
@@ -410,7 +410,7 @@ static int mod_init(void)
410 410
 	 * will be started; however we started already our
411 411
 	 * timers, so we know and process_count should not
412 412
 	 * change any more
413
-	 */	
413
+	 */
414 414
 	if (init_tm_stats()<0) {
415 415
 		LOG(L_CRIT, "ERROR: mod_init: failed to init stats\n");
416 416
 		return -1;
... ...
@@ -608,7 +608,7 @@ inline static int w_t_reply(struct sip_msg* msg, char* str, char* str2)
608 608
 	 * is called; we are already in a mutex and another mutex in
609 609
 	 * the safe version would lead to a deadlock
610 610
 	 */
611
-	if (rmode==MODE_ONFAILURE) { 
611
+	if (rmode==MODE_ONFAILURE) {
612 612
 		DBG("DEBUG: t_reply_unsafe called from w_t_reply\n");
613 613
 		return t_reply_unsafe(t, msg, (unsigned int)(long) str, str2);
614 614
 	} else if (rmode==MODE_REQUEST) {
... ...
@@ -625,7 +625,7 @@ inline static int w_t_release(struct sip_msg* msg, char* str, char* str2)
625 625
 	struct cell *t;
626 626
 	if (t_check( msg  , 0  )==-1) return -1;
627 627
 	t=get_t();
628
-	if ( t && t!=T_UNDEFINED ) 
628
+	if ( t && t!=T_UNDEFINED )
629 629
 		return t_release_transaction( t );
630 630
 	return 1;
631 631
 }
... ...
@@ -636,7 +636,7 @@ inline static int w_t_retransmit_reply( struct sip_msg* p_msg, char* foo, char*
636 636
 	struct cell *t;
637 637
 
638 638
 
639
-	if (t_check( p_msg  , 0 )==-1) 
639
+	if (t_check( p_msg  , 0 )==-1)
640 640
 		return 1;
641 641
 	t=get_t();
642 642
 	if (t) {
... ...
@@ -645,12 +645,12 @@ inline static int w_t_retransmit_reply( struct sip_msg* p_msg, char* foo, char*
645 645
 			return -1;
646 646
 		}
647 647
 		return t_retransmit_reply( t );
648
-	} else 
648
+	} else
649 649
 		return -1;
650 650
 }
651 651
 
652 652
 
653
-inline static int w_t_newtran( struct sip_msg* p_msg, char* foo, char* bar ) 
653
+inline static int w_t_newtran( struct sip_msg* p_msg, char* foo, char* bar )
654 654
 {
655 655
 	/* t_newtran returns 0 on error (negative value means
656 656
 	   'transaction exists' */
... ...
@@ -679,12 +679,12 @@ inline static int w_t_on_reply( struct sip_msg* msg, char *go_to, char *foo )
679 679
 
680 680
 
681 681
 
682
-inline static int _w_t_relay_to( struct sip_msg  *p_msg , 
682
+inline static int _w_t_relay_to( struct sip_msg  *p_msg ,
683 683
 	struct proxy_l *proxy )
684 684
 {
685 685
 	struct cell *t;
686 686
 
687
-	if (rmode==MODE_ONFAILURE) { 
687
+	if (rmode==MODE_ONFAILURE) {
688 688
 		t=get_t();
689 689
 		if (!t || t==T_UNDEFINED) {
690 690
 			LOG(L_CRIT, "BUG: w_t_relay_to: undefined T\n");
... ...
@@ -696,7 +696,7 @@ inline static int _w_t_relay_to( struct sip_msg  *p_msg ,
696 696
 		}
697 697
 		return 1;
698 698
 	}
699
-	if (rmode==MODE_REQUEST) 
699
+	if (rmode==MODE_REQUEST)
700 700
 		return t_relay_to( p_msg, proxy, PROTO_NONE,
701 701
 			0 /* no replication */ );
702 702
 	LOG(L_CRIT, "ERROR: w_t_relay_to: unsupported mode: %d\n", rmode);
... ...
@@ -704,7 +704,7 @@ inline static int _w_t_relay_to( struct sip_msg  *p_msg ,
704 704
 }
705 705
 
706 706
 
707
-inline static int w_t_relay_to_udp( struct sip_msg  *p_msg , 
707
+inline static int w_t_relay_to_udp( struct sip_msg  *p_msg ,
708 708
 	char *proxy, /* struct proxy_l *proxy expected */
709 709
 	char *_foo       /* nothing expected */ )
710 710
 {
... ...
@@ -714,7 +714,7 @@ inline static int w_t_relay_to_udp( struct sip_msg  *p_msg ,
714 714
 
715 715
 
716 716
 #ifdef USE_TCP
717
-inline static int w_t_relay_to_tcp( struct sip_msg  *p_msg , 
717
+inline static int w_t_relay_to_tcp( struct sip_msg  *p_msg ,
718 718
 	char *proxy, /* struct proxy_l *proxy expected */
719 719
 	char *_foo       /* nothing expected */ )
720 720
 {
... ...
@@ -725,7 +725,7 @@ inline static int w_t_relay_to_tcp( struct sip_msg  *p_msg ,
725 725
 
726 726
 
727 727
 #ifdef USE_TLS
728
-inline static int w_t_relay_to_tls( struct sip_msg  *p_msg , 
728
+inline static int w_t_relay_to_tls( struct sip_msg  *p_msg ,
729 729
 	char *proxy, /* struct proxy_l *proxy expected */
730 730
 	char *_foo       /* nothing expected */ )
731 731
 {
... ...
@@ -735,7 +735,7 @@ inline static int w_t_relay_to_tls( struct sip_msg  *p_msg ,
735 735
 #endif
736 736
 
737 737
 
738
-inline static int w_t_replicate( struct sip_msg  *p_msg , 
738
+inline static int w_t_replicate( struct sip_msg  *p_msg ,
739 739
 	char *proxy, /* struct proxy_l *proxy expected */
740 740
 	char *_foo       /* nothing expected */ )
741 741
 {
... ...
@@ -743,7 +743,7 @@ inline static int w_t_replicate( struct sip_msg  *p_msg ,
743 743
 }
744 744
 
745 745
 
746
-inline static int w_t_replicate_udp( struct sip_msg  *p_msg , 
746
+inline static int w_t_replicate_udp( struct sip_msg  *p_msg ,
747 747
 	char *proxy, /* struct proxy_l *proxy expected */
748 748
 	char *_foo       /* nothing expected */ )
749 749
 {
... ...
@@ -752,7 +752,7 @@ inline static int w_t_replicate_udp( struct sip_msg  *p_msg ,
752 752
 
753 753
 
754 754
 #ifdef USE_TCP
755
-inline static int w_t_replicate_tcp( struct sip_msg  *p_msg , 
755
+inline static int w_t_replicate_tcp( struct sip_msg  *p_msg ,
756 756
 	char *proxy, /* struct proxy_l *proxy expected */
757 757
 	char *_foo       /* nothing expected */ )
758 758
 {
... ...
@@ -762,7 +762,7 @@ inline static int w_t_replicate_tcp( struct sip_msg  *p_msg ,
762 762
 
763 763
 
764 764
 #ifdef USE_TLS
765
-inline static int w_t_replicate_tls( struct sip_msg  *p_msg , 
765
+inline static int w_t_replicate_tls( struct sip_msg  *p_msg ,
766 766
 	char *proxy, /* struct proxy_l *proxy expected */
767 767
 	char *_foo       /* nothing expected */ )
768 768
 {
... ...
@@ -771,25 +771,25 @@ inline static int w_t_replicate_tls( struct sip_msg  *p_msg ,
771 771
 #endif
772 772
 
773 773
 
774
-inline static int w_t_relay( struct sip_msg  *p_msg , 
774
+inline static int w_t_relay( struct sip_msg  *p_msg ,
775 775
 						char *_foo, char *_bar)
776 776
 {
777 777
 	struct cell *t;
778 778
 
779
-	if (rmode==MODE_ONFAILURE) { 
779
+	if (rmode==MODE_ONFAILURE) {
780 780
 		t=get_t();
781 781
 		if (!t || t==T_UNDEFINED) {
782 782
 			LOG(L_CRIT, "BUG: w_t_relay: undefined T\n");
783 783
 			return -1;
784
-		} 
784
+		}
785 785
 		if (t_forward_nonack(t, p_msg, ( struct proxy_l *) 0, PROTO_NONE)<=0) {
786 786
 			LOG(L_ERR, "ERROR: w_t_relay (failure mode): forwarding failed\n");
787 787
 			return -1;
788 788
 		}
789 789
 		return 1;
790 790
 	}
791
-	if (rmode==MODE_REQUEST) 
792
-		return t_relay_to( p_msg, 
791
+	if (rmode==MODE_REQUEST)
792
+		return t_relay_to( p_msg,
793 793
 		(struct proxy_l *) 0 /* no proxy */, PROTO_NONE,
794 794
 		0 /* no replication */ );
795 795
 	LOG(L_CRIT, "ERROR: w_t_relay_to: unsupported mode: %d\n", rmode);
... ...
@@ -800,7 +800,7 @@ inline static int w_t_relay( struct sip_msg  *p_msg ,
800 800
 /* set fr_inv_timeout & or fr_timeout; 0 means: use the default value */
801 801
 static int t_set_fr_all(struct sip_msg* msg, char* fr_inv, char* fr)
802 802
 {
803
-	
803
+
804 804
 	return t_set_fr(msg, (unsigned int)(long)fr_inv, (unsigned int)(long)fr);
805 805
 }
806 806
 
... ...
@@ -20,8 +20,8 @@
20 20
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
21 21
  * GNU General Public License for more details.
22 22
  *
23
- * You should have received a copy of the GNU General Public License 
24
- * along with this program; if not, write to the Free Software 
23
+ * You should have received a copy of the GNU General Public License
24
+ * along with this program; if not, write to the Free Software
25 25
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
26 26
  *
27 27
  * History:
... ...
@@ -147,6 +147,8 @@ typedef struct avp_spec {
147 147
 #define AVP_INDEX_BACKWARD	(1<<11)
148 148
 #define AVP_INDEX_ALL		(AVP_INDEX_FORWARD | AVP_INDEX_BACKWARD)
149 149
 
150
+#define AVP_FLAG_DIALOG         (1<<12)
151
+
150 152
 #define GALIAS_CHAR_MARKER  '$'
151 153
 
152 154
 /* Initialize memory structures */