Przeglądaj źródła

- removed obsoleted fifo comments
- replaced sl_send_reply with sl_reply
- lots of beautifications (no functional changes)

Nils Ohlmeier 18 lat temu
rodzic
commit
986a4ea041
1 zmienionych plików z 17 dodań i 21 usunięć
  1. 17 21
      etc/ser-basic.cfg

+ 17 - 21
etc/ser-basic.cfg

@@ -25,9 +25,6 @@ rev_dns=no      # (cmd. line: -R)
 #children=4
 #user=ser
 #group=ser
-#fifo_user=ser # owner of the ser fifo
-#fifo_group=ser
-#fifo_mode=0660 # fifo's permissions
 #disable_core=yes #disables core dumping
 #open_fd_limit=1024 # sets the open file descriptors limit
 #mhomed=yes  # usefull for multihomed hosts, small performance penalty
@@ -75,35 +72,35 @@ route{
 	# initial sanity checks -- messages with
 	# max_forwards==0, or excessively long requests
 	if (!mf_process_maxfwd_header("10")) {
-		sl_send_reply("483","Too Many Hops");
+		sl_reply("483","Too Many Hops");
 		break;
-	};
+	}
 	if (msg:len >=  max_len ) {
-		sl_send_reply("513", "Message too big");
+		sl_reply("513", "Message too big");
 		break;
-	};
-	
+	}
+
 	# we record-route all messages -- to make sure that
 	# subsequent messages will go through our proxy; that's
 	# particularly good if upstream and downstream entities
 	# use different transport protocol
-	if (!method=="REGISTER") record_route();	
+	if (!method=="REGISTER") record_route();
 
 	# subsequent messages withing a dialog should take the
 	# path determined by record-routing
 	if (loose_route()) {
 		# mark routing logic in request
-		append_hf("P-hint: rr-enforced\r\n"); 
+		append_hf("P-hint: rr-enforced\r\n");
 		route(FORWARD);
 		break;
-	};
+	}
 
 	if (!uri==myself) {
 		# mark routing logic in request
-		append_hf("P-hint: outbound\r\n"); 
+		append_hf("P-hint: outbound\r\n");
 		route(FORWARD);
 		break;
-	};
+	}
 
 	# if the request is for other domain use UsrLoc
 	# (in case, it does not work, use the following command
@@ -111,27 +108,26 @@ route{
 	if (uri==myself) {
 
 		if (method=="REGISTER") {
-
 			save_contacts("location");
 			break;
-		};
+		}
 
 		# native SIP destinations are handled using our USRLOC DB
 		if (!lookup_contacts("location")) {
-			sl_send_reply("404", "Not Found");
+			sl_reply("404", "Not Found");
 			break;
-		};
-		append_hf("P-hint: usrloc applied\r\n"); 
-	};
+		}
+		append_hf("P-hint: usrloc applied\r\n");
+	}
 	route(FORWARD);
 }
 
-route[FORWARD] 
+route[FORWARD]
 {
 	# send it out now; use stateful forwarding as it works reliably
 	# even for UDP2TCP
 	if (!t_relay()) {
 		sl_reply_error();
-	};
+	}
 }