Browse code

- minor serdev doc edits - removed fifo default value - added -i fifo_path parameter - updated man page

Andrei Pelinescu-Onciul authored on 25/09/2002 10:03:20
Showing 5 changed files
... ...
@@ -1,4 +1,5 @@
1
-<!DOCTYPE Book SYSTEM "/usr/share/sgml/docbook/dtd-4.2/docbook.dtd">
1
+<!-- $Id$ -->
2
+<!DOCTYPE Book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
2 3
 
3 4
 <book label="serdev" id="serdev" lang="EN">
4 5
     <title>SIP Express Router</title>
... ...
@@ -93,8 +94,8 @@
93 93
 	<section id="cmd-line-params">
94 94
 	    <title>Processing Command Line Parameters</title>
95 95
 	    <para>
96
-		<acronym>SER</acronym> utilizes <acronym>GNU</acronym><function moreinfo="none">getopt</function>function to 
97
-		parse command line parameters.
96
+		<acronym>SER</acronym> utilizes the <function moreinfo="none">getopt
97
+		</function>function to parse command line parameters.
98 98
 		The function is extensively described in the man pages.
99 99
 	    </para>
100 100
 	</section> <!-- cmd-line-params -->
... ...
@@ -242,18 +243,18 @@
242 242
 		    will be issued and the server will be aborted.
243 243
 		</para>
244 244
 		<para>
245
-		    There is a utility called Bison. Input of the utility is a file containing the grammar of
245
+		    There is a utility called yacc. Input of the utility is a file containing the grammar of
246 246
 		    the configuration file, in addition to the grammar, you can describe what action the parser
247 247
 		    should do at various stages of parsing. For example, you can instruct the parser to create a
248 248
 		    structure describing an <acronym>IP</acronym> address every time it finds an <acronym>IP</acronym> 
249 249
 		    address in the configuration file and convert the address to its binary representation.
250 250
 		</para>
251
-		<para>For more information see Bison documentation.</para>
251
+		<para>For more information see yacc documentation.</para>
252 252
 		<para>
253
-		    Bison creates the parser when the server is being compiled from the sources.
254
-		    Input file for bison is <filename moreinfo="none">cfg.y</filename>. The file contains grammar
253
+		    yacc creates the parser when the server is being compiled from the sources.
254
+		    Input file for yacc is <filename moreinfo="none">cfg.y</filename>. The file contains grammar
255 255
 		    of the config file along with actions that create the binary representation of the file.
256
-		    Bison will write its result into file <filename moreinfo="none">cfg.tab.c</filename>. The
256
+		    Yacc will write its result into file <filename moreinfo="none">cfg.tab.c</filename>. The
257 257
 		    file contains function <function moreinfo="none">yyparse</function> which will parse the whole
258 258
 		    configuration file and construct the binary representation. For more information about the
259 259
 		    bison input file syntax see bison documentation.
... ...
@@ -76,7 +76,7 @@
76 76
 #include "pt.h"
77 77
 
78 78
 /* FIFO server vars */
79
-char *fifo="/tmp/ser_fifo"; /* FIFO name */
79
+char *fifo=0; /* FIFO name */
80 80
 int fifo_mode=S_IRUSR | S_IWUSR | S_IRGRP | 
81 81
 	S_IWGRP | S_IROTH | S_IWOTH;
82 82
 pid_t fifo_pid;
... ...
@@ -173,9 +173,10 @@ Options:\n\
173 173
     -t  dir      chroot to \"dir\"\n\
174 174
     -u uid       change uid \n\
175 175
     -g gid       change gid \n\
176
-    -P file      create a pid file\n"
176
+    -P file      create a pid file\n\
177
+    -i fifo_path create a fifo (usefull for monitoring " NAME ") \n"
177 178
 #ifdef STATS
178
-"    -s file	 File to which statistics is dumped (disabled otherwise)\n"
179
+"    -s file     File to which statistics is dumped (disabled otherwise)\n"
179 180
 #endif
180 181
 ;
181 182
 
... ...
@@ -917,7 +918,7 @@ int main(int argc, char** argv)
917 917
 #ifdef STATS
918 918
 	"s:"
919 919
 #endif
920
-	"f:p:m:b:l:n:rRvdDEVhw:t:u:g:P:";
920
+	"f:p:m:b:l:n:rRvdDEVhw:t:u:g:P:i:";
921 921
 	
922 922
 	while((c=getopt(argc,argv,options))!=-1){
923 923
 		switch(c){
... ...
@@ -1043,6 +1044,9 @@ int main(int argc, char** argv)
1043 1043
 			case 'P':
1044 1044
 					pid_file=optarg;
1045 1045
 					break;
1046
+			case 'i':
1047
+					fifo=optarg;
1048
+					break;
1046 1049
 			case '?':
1047 1050
 					if (isprint(optopt))
1048 1051
 						fprintf(stderr, "Unknown option `-%c�.\n", optopt);
... ...
@@ -1073,7 +1077,7 @@ int main(int argc, char** argv)
1073 1073
 	}
1074 1074
 
1075 1075
 
1076
-        init_hfname_parser();
1076
+	init_hfname_parser();
1077 1077
 	init_digest_parser();
1078 1078
 
1079 1079
 	/* init hash fucntion */
... ...
@@ -91,7 +91,9 @@ struct sip_msg {
91 91
 	int parsed_flag;               /* Already parsed header field types */
92 92
 
93 93
 	     /* Via, To, CSeq, Call-Id, From, end of header*/
94
-	     /* first occurance of it; subsequent occurances saved in 'headers' */
94
+	     /* pointers to the first occurances of these headers;
95
+		  * everything is also saved in 'headers'
96
+		  * (WARNING: do not deallocate them twice!)*/
95 97
 
96 98
 	struct hdr_field* h_via1;
97 99
 	struct hdr_field* h_via2;
... ...
@@ -32,6 +32,8 @@ ser \- very fast and configurable sip proxy
32 32
 .BI \-g " gid"
33 33
 ] [
34 34
 .BI \-P " pid\-file"
35
+] [
36
+.BI \-i " fifo\-path"
35 37
 ]
36 38
 
37 39
 .SH DESCRIPTION
... ...
@@ -126,6 +128,11 @@ runs.
126 126
 Creates a file containing the pid of the main 
127 127
 .B ser 
128 128
 process.
129
+.TP
130
+.BI \-i " fifo\-path"
131
+Creates a fifo, usefull for monitoring
132
+.B ser
133
+status.
129 134
 
130 135
 
131 136
 .SH FILES