Browse code

*** empty log message ***

Bogdan-Andrei Iancu authored on 08/02/2002 14:29:34
Showing 3 changed files
... ...
@@ -53,7 +53,7 @@ ARCH = $(shell uname -s)
53 53
 
54 54
 DEFS+= -DNAME='"$(NAME)"' -DVERSION='"$(RELEASE)"' -DARCH='"$(ARCH)"' \
55 55
 	 -DDNS_IP_HACK  -DPKG_MALLOC -DSHM_MEM  -DSHM_MMAP \
56
-	 -DUSE_SYNONIM \
56
+	 -DUSE_SYNONIM -DVQ_MALLOC\
57 57
 	 #-DFAST_LOCK -Di386
58 58
 	 #-DBRUT_HACK #-DEXTRA_DEBUG #-DSTATIC_TM
59 59
 	#-DEXTRA_DEBUG -DBRUT_HACK \
... ...
@@ -68,8 +68,8 @@ DEFS+= -DNAME='"$(NAME)"' -DVERSION='"$(RELEASE)"' -DARCH='"$(ARCH)"' \
68 68
 #-DNO_LOG
69 69
 
70 70
 PROFILE=  -pg #set this if you want profiling
71
-mode = debug
72
-#mode = release
71
+#mode = debug
72
+mode = release
73 73
 
74 74
 # platform dependent settings
75 75
 
... ...
@@ -10,7 +10,7 @@
10 10
 #include "../../ut.h"
11 11
 
12 12
 
13
-#define ROUND4(s) ((s)%4)?((s)+4)/4*4:(s)
13
+#define ROUND4(s) (((s)%4)?((s)+4)/4*4:(s))
14 14
 
15 15
 #define  lump_len( _lump)  (ROUND4(sizeof(struct lump)) + \
16 16
                ROUND4( ((_lump)->op==LUMP_ADD)?(_lump)->len:0 ))
... ...
@@ -36,7 +36,7 @@ struct sip_msg*  sip_msg_cloner( struct sip_msg *org_msg )
36 36
    struct to_param   *to_prm,*new_to_prm;
37 37
    struct sip_msg     *new_msg;
38 38
    struct lump          *lump_chain, *lump_tmp, **lump_anchor, **lump_anchor2;
39
-   char                       *p;
39
+   char                       *p,*foo;
40 40
 
41 41
 
42 42
    /*computing the length of entire sip_msg structure*/
... ...
@@ -74,7 +74,7 @@ struct sip_msg*  sip_msg_cloner( struct sip_msg *org_msg )
74 74
                    break;
75 75
       }
76 76
    }
77
-   /* length of the data lump structures
77
+   /* length of the data lump structures */
78 78
    if (org_msg->first_line.type==SIP_REQUEST)
79 79
       lump_chain = org_msg->add_rm;
80 80
    else
... ...
@@ -95,9 +95,9 @@ struct sip_msg*  sip_msg_cloner( struct sip_msg *org_msg )
95 95
          lump_tmp = lump_tmp->after;
96 96
       }
97 97
       lump_chain = lump_chain->next;
98
-   }  */
98
+   }
99 99
 
100
-   p=(char *)sh_malloc(len);
100
+   p=(char *)sh_malloc(len);foo=p;
101 101
    if (!p)
102 102
    {
103 103
       LOG(L_ERR , "ERROR: sip_msg_cloner_2: cannot allocate memory\n" );
... ...
@@ -123,9 +123,9 @@ struct sip_msg*  sip_msg_cloner( struct sip_msg *org_msg )
123 123
    p += ROUND4(new_msg->len);
124 124
    /*unparsed and eoh pointer*/
125 125
    new_msg->unparsed = translate_pointer( new_msg->buf ,
126
-							org_msg->buf , org_msg->unparsed );
126
+	org_msg->buf , org_msg->unparsed );
127 127
    new_msg->eoh = translate_pointer( new_msg->buf ,
128
-							org_msg->buf , org_msg->eoh );
128
+	org_msg->buf , org_msg->eoh );
129 129
    /* first line, updating the pointers*/
130 130
    if ( org_msg->first_line.type==SIP_REQUEST )
131 131
    {
... ...
@@ -255,7 +255,7 @@ struct sip_msg*  sip_msg_cloner( struct sip_msg *org_msg )
255 255
 
256 256
    }
257 257
 
258
-   /* clonning data lump
258
+   /* clonning data lump*/
259 259
    if (org_msg->first_line.type==SIP_REQUEST) {
260 260
       lump_chain = org_msg->add_rm;
261 261
       lump_anchor = &(new_msg->add_rm);
... ...
@@ -266,7 +266,7 @@ struct sip_msg*  sip_msg_cloner( struct sip_msg *org_msg )
266 266
    while (lump_chain)
267 267
    {
268 268
       lump_clone( (*lump_anchor) , lump_chain , p );
269
-      /*before list/
269
+      /*before list*/
270 270
       lump_tmp = lump_chain->before;
271 271
       lump_anchor2 = &((*lump_anchor)->before);
272 272
       while ( lump_tmp )
... ...
@@ -275,7 +275,7 @@ struct sip_msg*  sip_msg_cloner( struct sip_msg *org_msg )
275 275
          lump_anchor2 = &((*lump_anchor2)->before);
276 276
          lump_tmp = lump_tmp->before;
277 277
       }
278
-      /*after list/
278
+      /*after list*/
279 279
       lump_tmp = lump_chain->after;
280 280
       lump_anchor2 = &((*lump_anchor)->after);
281 281
       while ( lump_tmp )
... ...
@@ -286,8 +286,8 @@ struct sip_msg*  sip_msg_cloner( struct sip_msg *org_msg )
286 286
       }
287 287
       lump_anchor = &((*lump_anchor)->next);
288 288
       lump_chain = lump_chain->next;
289
-   }           */
290
-
289
+   }
290
+   DBG("-----------> len=%d <---> written=%d\n",len,p-foo);
291 291
    return new_msg;
292 292
 }
293 293
 
... ...
@@ -5,7 +5,7 @@
5 5
 #
6 6
 
7 7
 
8
-debug=3          # debug level (cmd line: -dddddddddd)
8
+debug=9          # debug level (cmd line: -dddddddddd)
9 9
 #fork=yes          # (cmd. line: -D)
10 10
 fork=no
11 11
 log_stderror=yes # (cmd line: -E)
... ...
@@ -17,16 +17,16 @@ check_via=no     # (cmd. line: -v)
17 17
 dns=on           # (cmd. line: -r)
18 18
 rev_dns=yes      # (cmd. line: -R)
19 19
 #port=5070
20
-listen=127.0.0.1
20
+#listen=127.0.0.1
21 21
 #listen=192.168.57.33
22 22
 loop_checks=0
23 23
 # for more info: sip_router -h
24 24
 
25 25
 #modules
26 26
 #loadmodule "modules/print/print.so"
27
-#loadmodule "modules/tm/tm.so"
28
-#loadmodule "modules/rr/rr.so"
29
-#loadmodule "modules/maxfwd/maxfwd.so"
27
+loadmodule "modules/tm/tm.so"
28
+loadmodule "modules/rr/rr.so"
29
+loadmodule "modules/maxfwd/maxfwd.so"
30 30
 
31 31
 
32 32
 route{