Index: .hgtags
===================================================================
--- .hgtags	(revision 971)
+++ .hgtags	(revision 961)
@@ -32,5 +32,2 @@
 8500947421cb412b5f4f2dfffdf1a35b6fb369e0 FORK
 155d45d0653025f45b58ab96b6ba0d5e6fb7fcf8 1.1.6
-8500947421cb412b5f4f2dfffdf1a35b6fb369e0 FORK
-0000000000000000000000000000000000000000 FORK
-ec348f6043998ca77d2b3122ef47157c82055ccd proposed_merged
Index: INSTALL.OSX
===================================================================
--- INSTALL.OSX	(revision 887)
+++ INSTALL.OSX	(revision 972)
@@ -43,5 +43,5 @@
 
    Notes:
-    * GNU IDN (libidn) is optional, see bellow
+    * GNU IDN (libidn) is optional, see below
     * When libusrsctp package is available, you can use it as well.
 
Index: INSTALL.Ubuntu
===================================================================
--- INSTALL.Ubuntu	(revision 877)
+++ INSTALL.Ubuntu	(revision 972)
@@ -73,5 +73,5 @@
 ===========================================
 
-freeDiameter has been tested on the following distributions (compiled from source as described bellow):
+freeDiameter has been tested on the following distributions (compiled from source as described below):
 Ubuntu Intrepid, Jaunty, Karmic, Lucid, Maverick, Natty. 
 Debian Lenny (with small patch, see ticket #24).
Index: README
===================================================================
--- README	(revision 660)
+++ README	(revision 972)
@@ -19,5 +19,5 @@
       the network connections with other Diameter peers and performs the tasks described 
       in Diameter Base Protocol, such as watchdogs, basic routing, ... It also handles 
-      the loading of extensions (see bellow).
+      the loading of extensions (see below).
       
  - freeDiameterd : this simple daemon parses the command line and initializes the
Index: contrib/OpenWRT/packages/freeDiameter/Makefile
===================================================================
--- contrib/OpenWRT/packages/freeDiameter/Makefile	(revision 707)
+++ contrib/OpenWRT/packages/freeDiameter/Makefile	(revision 972)
@@ -124,5 +124,5 @@
 							>> $(1)/etc/freeDiameter/freeDiameter.conf
 	echo "# LoadExtension = \"test_app.fdx\";"	>> $(1)/etc/freeDiameter/freeDiameter.conf
-	echo "## Add overrides bellow this point" 	>> $(1)/etc/freeDiameter/freeDiameter.conf
+	echo "## Add overrides below this point" 	>> $(1)/etc/freeDiameter/freeDiameter.conf
 
 	
Index: contrib/app_acct_tools/display_results.php
===================================================================
--- contrib/app_acct_tools/display_results.php	(revision 533)
+++ contrib/app_acct_tools/display_results.php	(revision 972)
@@ -4,5 +4,5 @@
 
 # This file should no be called directly; 
-# instead it should be included from another script that sets its parameters as described bellow.
+# instead it should be included from another script that sets its parameters as described below.
 
 ## $USERS  
Index: doc/app_redirect.conf.sample
===================================================================
--- doc/app_redirect.conf.sample	(revision 722)
+++ doc/app_redirect.conf.sample	(revision 972)
@@ -12,5 +12,5 @@
 ## default_redirect_cache_time
 # Specify the default value for Redirect-Max-Cache-Time.
-# This value can be overwriten for each rule as specified bellow.
+# This value can be overwriten for each rule as specified below.
 # If this value is not specified, the default is:
 #default_redirect_cache_time = 86400;  ## => 1 day
Index: doc/freediameter.conf.sample
===================================================================
--- doc/freediameter.conf.sample	(revision 925)
+++ doc/freediameter.conf.sample	(revision 972)
@@ -194,5 +194,5 @@
 # be configured to establish and maintain connections to some 
 # Diameter nodes and allow connections from these nodes.
-#  This is achieved with the ConnectPeer directive described bellow.
+#  This is achieved with the ConnectPeer directive described below.
 #
 # Note that the configured Diameter Id MUST match
Index: extensions/app_radgw/md5.c
===================================================================
--- extensions/app_radgw/md5.c	(revision 403)
+++ extensions/app_radgw/md5.c	(revision 972)
@@ -3,5 +3,5 @@
  *  The content from this file comes directly from the hostap project.
  * It is redistributed under the terms of the BSD license, as allowed
- * by the original copyright reproduced bellow.
+ * by the original copyright reproduced below.
  *  In addition to this notice, only the #include directives have been modified.
  */
Index: extensions/app_radgw/md5.h
===================================================================
--- extensions/app_radgw/md5.h	(revision 403)
+++ extensions/app_radgw/md5.h	(revision 972)
@@ -3,5 +3,5 @@
  *  The content from this file comes directly from the hostap project.
  * It is redistributed under the terms of the BSD license, as allowed
- * by the original copyright reproduced bellow.
+ * by the original copyright reproduced below.
  */
 
Index: extensions/app_radgw/radius.c
===================================================================
--- extensions/app_radgw/radius.c	(revision 741)
+++ extensions/app_radgw/radius.c	(revision 972)
@@ -37,5 +37,5 @@
  *  The content from this file comes for the main part from the hostap project.
  * It is redistributed under the terms of the BSD license, as allowed
- * by the original copyright reproduced bellow.
+ * by the original copyright reproduced below.
  * The modifications to this file are placed under the copyright of the freeDiameter project.
  */
Index: extensions/app_radgw/radius.h
===================================================================
--- extensions/app_radgw/radius.h	(revision 741)
+++ extensions/app_radgw/radius.h	(revision 972)
@@ -38,5 +38,5 @@
  *  The content from this file comes mostly from the hostap project.
  * It is redistributed under the terms of the BSD license, as allowed
- * by the original copyright reproduced bellow.
+ * by the original copyright reproduced below.
  * The changes to this file are placed under the copyright of the freeDiameter project.
  */
Index: extensions/app_radgw/rgwx_auth.c
===================================================================
--- extensions/app_radgw/rgwx_auth.c	(revision 928)
+++ extensions/app_radgw/rgwx_auth.c	(revision 972)
@@ -1099,5 +1099,5 @@
         	 Request will have access to the Session Identifier and be able
         	 to set the Destination-Host to the correct value.
-		 	-> done here bellow
+		 	-> done here below
 		 
 	      -  If the Command-Code is set to AA-Answer, the Diameter Session-
Index: extensions/app_sip/app_sip.c
===================================================================
--- extensions/app_sip/app_sip.c	(revision 732)
+++ extensions/app_sip/app_sip.c	(revision 972)
@@ -122,5 +122,5 @@
 	
 	
-	//We set usefull AVPs 
+	//We set useful AVPs 
 	CHECK_FCT( fd_dict_search( fd_g_config->cnf_dict, DICT_AVP, AVP_BY_NAME, "Auth-Session-State", &sip_dict.Auth_Session_State, ENOENT) );
 	CHECK_FCT( fd_dict_search( fd_g_config->cnf_dict, DICT_AVP, AVP_BY_NAME, "Auth-Application-Id", &sip_dict.Auth_Application_Id, ENOENT) );
Index: extensions/app_sip/app_sip.h
===================================================================
--- extensions/app_sip/app_sip.h	(revision 959)
+++ extensions/app_sip/app_sip.h	(revision 972)
@@ -218,5 +218,5 @@
 };
 
-//Storage for some usefull AVPs
+//Storage for some useful AVPs
 struct app_sip_dict{
 	struct dict_object * Auth_Session_State;
Index: extensions/app_sip/md5.c
===================================================================
--- extensions/app_sip/md5.c	(revision 433)
+++ extensions/app_sip/md5.c	(revision 972)
@@ -3,5 +3,5 @@
  *  The content from this file comes directly from the hostap project.
  * It is redistributed under the terms of the BSD license, as allowed
- * by the original copyright reproduced bellow.
+ * by the original copyright reproduced below.
  *  In addition to this notice, only the #include directives have been modified.
  */
Index: extensions/app_sip/md5.h
===================================================================
--- extensions/app_sip/md5.h	(revision 360)
+++ extensions/app_sip/md5.h	(revision 972)
@@ -3,5 +3,5 @@
  *  The content from this file comes directly from the hostap project.
  * It is redistributed under the terms of the BSD license, as allowed
- * by the original copyright reproduced bellow.
+ * by the original copyright reproduced below.
  *  The file has not been modified, except for this notice.
  */
Index: extensions/dbg_interactive/dictionary.i
===================================================================
--- extensions/dbg_interactive/dictionary.i	(revision 741)
+++ extensions/dbg_interactive/dictionary.i	(revision 972)
@@ -197,5 +197,5 @@
 /* The following wrapper leaks memory each time an union avp_value is assigned an octet string.
  TODO: fix this leak by better understanding SWIG... 
-   -- the alternative is to uncomment the "free" statements bellow, but then it is easy to
+   -- the alternative is to uncomment the "free" statements below, but then it is easy to
    create a segmentation fault by assigning first an integer, then an octetstring.
  */
Index: extensions/test_netemul/tne_process.c
===================================================================
--- extensions/test_netemul/tne_process.c	(revision 740)
+++ extensions/test_netemul/tne_process.c	(revision 972)
@@ -58,5 +58,5 @@
 static pthread_t       thr = (pthread_t)NULL;
 
-/* The lists bellow are all protected by the same mutex mtx */
+/* The lists below are all protected by the same mutex mtx */
 static struct fd_list input = FD_LIST_INITIALIZER(input); /* messages received from network */
 static struct fd_list forlat = FD_LIST_INITIALIZER(forlat); /* messages after duplicate filter */
Index: extensions/test_sip/test_sip.c
===================================================================
--- extensions/test_sip/test_sip.c	(revision 732)
+++ extensions/test_sip/test_sip.c	(revision 972)
@@ -127,5 +127,5 @@
 	
 	
-	//We set usefull AVPs 
+	//We set useful AVPs 
 	CHECK_FCT( fd_dict_search( fd_g_config->cnf_dict, DICT_AVP, AVP_BY_NAME, "Auth-Session-State", &sip_dict.Auth_Session_State, ENOENT) );
 	CHECK_FCT( fd_dict_search( fd_g_config->cnf_dict, DICT_AVP, AVP_BY_NAME, "Auth-Application-Id", &sip_dict.Auth_Application_Id, ENOENT) );
Index: extensions/test_sip/test_sip.h
===================================================================
--- extensions/test_sip/test_sip.h	(revision 959)
+++ extensions/test_sip/test_sip.h	(revision 972)
@@ -55,5 +55,5 @@
 extern struct ts_conf * ts_conf;
 
-//Storage for some usefull AVPs
+//Storage for some useful AVPs
 struct sip_dict{
 	struct dict_object * Auth_Session_State;
Index: include/freeDiameter/libfdcore.h
===================================================================
--- include/freeDiameter/libfdcore.h	(revision 968)
+++ include/freeDiameter/libfdcore.h	(revision 972)
@@ -225,5 +225,5 @@
 	(((unsigned)(state)) <= STATE_MAX ? peer_state_str[((unsigned)(state)) ] : "<Invalid>")
 
-/* Constants for the peer_info structure bellow */
+/* Constants for the peer_info structure below */
 #define PI_P3_DEFAULT	0	/* Use any available protocol */
 #define PI_P3_IP	1	/* Use only IP to connect to this peer */
@@ -406,5 +406,5 @@
  *
  * PARAMETERS:
- *  peer_validate 	: Callback as defined bellow.
+ *  peer_validate 	: Callback as defined below.
  *
  * DESCRIPTION: 
@@ -589,8 +589,8 @@
  *   - The process is the same as for IN messages, until the routing-in threads makes its decision that the message is not handled locally.
  *   - If the local peer does not relay message, an error DIAMETER_APPLICATION_UNSUPPORTED is returned.
- *   - All callbacks registered with fd_rt_fwd_register are called for the message (see bellow).
+ *   - All callbacks registered with fd_rt_fwd_register are called for the message (see below).
  *     - these callbacks will typically do proxying work. Note that adding the route-record is handled by the daemon.
  *   - Once all callbacks have been called, the message is queued in the global fd_g_outgoing queue.
- *   - The remaining processing is the same as for OUT messages, as described bellow.
+ *   - The remaining processing is the same as for OUT messages, as described below.
  *
  * (*) OUT messages details:
@@ -602,5 +602,5 @@
  *   - If the list is empty, create an error UNABLE_TO_DELIVER (note: should we trig dynamic discovery here???) and reply.
  *   - Otherwise, call all callbacks registered by function fd_rt_out_register, with the list of peers and the message.
- *   - Order the resulting list of peers by score (see bellow), and sent the message to the peer with highest (positive) score.
+ *   - Order the resulting list of peers by score (see below), and sent the message to the peer with highest (positive) score.
  *    - in case the peer is no longer in the "OPEN" state, send the message to the second peer in the list.
  *      - if no peer is in OPEN state anymore, restart the process of creating the list.
@@ -626,5 +626,5 @@
  *
  * PARAMETERS:
- *  rt_fwd_cb	  : The callback function to register (see prototype bellow).
+ *  rt_fwd_cb	  : The callback function to register (see prototype below).
  *  cbdata	  : Pointer to pass to the callback when it is called. The data is opaque to the daemon.
  *  dir           : One of the RT_FWD_* directions defined above.
@@ -703,5 +703,5 @@
  *
  * PARAMETERS:
- *  rt_out_cb	  : The callback function to register (see prototype bellow).
+ *  rt_out_cb	  : The callback function to register (see prototype below).
  *  cbdata	  : Pointer to pass to the callback when it is called. The data is opaque to the daemon.
  *  priority      : Order for calling this callback. The callbacks are called in reverse priority order (higher priority = called sooner).
Index: include/freeDiameter/libfdproto.h
===================================================================
--- include/freeDiameter/libfdproto.h	(revision 965)
+++ include/freeDiameter/libfdproto.h	(revision 972)
@@ -284,5 +284,5 @@
 	TRACE(FD_LOG_DEBUG,(level),format,##args)
 
-/* Report a normal message that is usefull for normal admin monitoring */
+/* Report a normal message that is useful for normal admin monitoring */
 #define TRACE_NOTICE(format,args... ) \
 	TRACE(FD_LOG_NOTICE,INFO,format,##args)
@@ -312,5 +312,5 @@
 int fd_breakhere(void);
 
-/* Helper for tracing the CHECK_* macros bellow -- very very verbose code execution! */
+/* Helper for tracing the CHECK_* macros below -- very very verbose code execution! */
 #define TRACE_DEBUG_ALL( str ) 	\
 	TRACE_DEBUG(CALL, str );
@@ -894,5 +894,5 @@
  *  type 	: What kind of object must be created
  *  data 	: pointer to the data for the object. 
- *          	 type parameter is used to determine the type of data (see bellow for detail).
+ *          	 type parameter is used to determine the type of data (see below for detail).
  *  parent 	: a reference to a parent object, if needed.
  *  ref 	: upon successful creation, reference to new object is stored here if !null.
@@ -918,5 +918,5 @@
  *  dict	: Pointer to the dictionnary where the object is searched
  *  type 	: type of object that is being searched
- *  criteria 	: how the object must be searched. See object-related sections bellow for more information.
+ *  criteria 	: how the object must be searched. See object-related sections below for more information.
  *  what 	: depending on criteria, the data that must be searched.
  *  result 	: On successful return, pointer to the object is stored here.
@@ -925,5 +925,5 @@
  * DESCRIPTION: 
  *   Perform a search in the dictionary. 
- *   See the object-specific sections bellow to find how to look for each objects.
+ *   See the object-specific sections below to find how to look for each objects.
  *   If the "result" parameter is NULL, the function is used to check if an object is in the dictionary.
  *   Otherwise, a reference to the object is stored in result if found.
@@ -995,5 +995,5 @@
 	VENDOR_BY_ID = 10,	/* "what" points to a vendor_id_t */
 	VENDOR_BY_NAME,		/* "what" points to a char * */
-	VENDOR_OF_APPLICATION	/* "what" points to a struct dict_object containing an application (see bellow) */
+	VENDOR_OF_APPLICATION	/* "what" points to a struct dict_object containing an application (see below) */
 };
 
@@ -1065,6 +1065,6 @@
 	APPLICATION_BY_ID = 20,		/* "what" points to a application_id_t */
 	APPLICATION_BY_NAME,		/* "what" points to a char * */
-	APPLICATION_OF_TYPE,		/* "what" points to a struct dict_object containing a type object (see bellow) */
-	APPLICATION_OF_COMMAND		/* "what" points to a struct dict_object containing a command (see bellow) */
+	APPLICATION_OF_TYPE,		/* "what" points to a struct dict_object containing a type object (see below) */
+	APPLICATION_OF_COMMAND		/* "what" points to a struct dict_object containing a command (see below) */
 };
 
@@ -1206,5 +1206,5 @@
 enum {
 	TYPE_BY_NAME = 30,		/* "what" points to a char * */
-	TYPE_OF_ENUMVAL,		/* "what" points to a struct dict_object containing an enumerated constant (DICT_ENUMVAL, see bellow). */
+	TYPE_OF_ENUMVAL,		/* "what" points to a struct dict_object containing an enumerated constant (DICT_ENUMVAL, see below). */
 	TYPE_OF_AVP			/* "what" points to a struct dict_object containing an AVP object. */
 };
@@ -1280,5 +1280,5 @@
 /* The criteria for searching a constant in the dictionary */
 enum {
-	ENUMVAL_BY_STRUCT = 40,	/* "what" points to a struct dict_enumval_request as defined bellow */
+	ENUMVAL_BY_STRUCT = 40,	/* "what" points to a struct dict_enumval_request as defined below */
 	ENUMVAL_BY_NAME,	/* This cannot be used for researches */
 	ENUMVAL_BY_VALUE	/* This cannot be used for researches */
@@ -1402,9 +1402,9 @@
 	AVP_BY_NAME,		/* "what" points to a char *, vendor is always 0 */
 	AVP_BY_NAME_ALL_VENDORS,/* "what" points to a string. Might be quite slow... */
-	AVP_BY_STRUCT,		/* "what" points to a struct dict_avp_request_ex (see bellow) */
+	AVP_BY_STRUCT,		/* "what" points to a struct dict_avp_request_ex (see below) */
 			
 	/* kept for backward compatibility, better use AVP_BY_STRUCT above instead */
-	AVP_BY_CODE_AND_VENDOR,	/* "what" points to a struct dict_avp_request (see bellow), where avp_vendor and avp_code are set */
-	AVP_BY_NAME_AND_VENDOR	/* "what" points to a struct dict_avp_request (see bellow), where avp_vendor and avp_name are set */
+	AVP_BY_CODE_AND_VENDOR,	/* "what" points to a struct dict_avp_request (see below), where avp_vendor and avp_code are set */
+	AVP_BY_NAME_AND_VENDOR	/* "what" points to a struct dict_avp_request (see below), where avp_vendor and avp_name are set */
 };
 
@@ -1640,5 +1640,5 @@
 /* The criteria for searching a rule in the dictionary */
 enum {
-	RULE_BY_AVP_AND_PARENT = 70	/* "what" points to a struct dict_rule_request -- see bellow. This is used to query "what is the rule for this AVP in this group?" */
+	RULE_BY_AVP_AND_PARENT = 70	/* "what" points to a struct dict_rule_request -- see below. This is used to query "what is the rule for this AVP in this group?" */
 };
 
@@ -1853,5 +1853,5 @@
  *  diamid	  : a Diameter Identity, or NULL.
  *  diamidlen	  : if diamid is \0-terminated, this can be 0. Otherwise, the length of diamid.
- *  opt           : Additional string, or NULL. Usage is described bellow.
+ *  opt           : Additional string, or NULL. Usage is described below.
  *  optlen	  : if opt is \0-terminated, this can be 0. Otherwise, the length of opt.
  *
@@ -2136,5 +2136,5 @@
 };
 
-/* Some flags used in the functions bellow */
+/* Some flags used in the functions below */
 #define AVPFL_SET_BLANK_VALUE	   0x01	/* When creating an AVP, initialize its value to a blank area */
 #define AVPFL_SET_RAWDATA_FROM_AVP 0x02 /* When creating an AVP, initialize its rawdata area from an existing AVP -- it is only blank padding (for error reporting) */
Index: libfdcore/p_psm.c
===================================================================
--- libfdcore/p_psm.c	(revision 931)
+++ libfdcore/p_psm.c	(revision 972)
@@ -54,5 +54,5 @@
 after the CER/CEA exchange (and initiated by the peer that sent the
 CEA), we have a simple way to deal with our ordering problem, as resumed
-bellow. Peers are: [i]nitiator, [r]esponder.
+below. Peers are: [i]nitiator, [r]esponder.
  (1) [i] SCTP connection attempt.
  (2) [r] accept the connection.
Index: libfdcore/peers.c
===================================================================
--- libfdcore/peers.c	(revision 968)
+++ libfdcore/peers.c	(revision 972)
@@ -542,5 +542,5 @@
 		fd_list_insert_after( li_inf, &peer->p_hdr.chain );
 		
-		/* Start the PSM, which will receive the event bellow */
+		/* Start the PSM, which will receive the event below */
 		CHECK_FCT_DO( ret = fd_psm_begin(peer), goto out );
 	} else {
Index: libfdproto/dictionary.c
===================================================================
--- libfdproto/dictionary.c	(revision 961)
+++ libfdproto/dictionary.c	(revision 972)
@@ -79,9 +79,9 @@
 	/* More information about the lists :
 	
-	 - the use for each list depends on the type of object. See detail bellow.
+	 - the use for each list depends on the type of object. See detail below.
 	 
 	 - a sentinel for a list has its 'o' field cleared. (this is the criteria to detect end of a loop)
 	 
-	 - The lists are always ordered. The criteria are described bellow. the functions to order them are referenced in dict_obj_info
+	 - The lists are always ordered. The criteria are described below. the functions to order them are referenced in dict_obj_info
 	 
 	 - The dict_lock must be held for any list operation.
Index: tests/testfifo.c
===================================================================
--- tests/testfifo.c	(revision 879)
+++ tests/testfifo.c	(revision 972)
@@ -302,5 +302,5 @@
 		} else {
 			TRACE_DEBUG(INFO, "Local limit on number of threads: %d", nbr_threads);
-			/* The local limit is bellow NBR_THREADS */
+			/* The local limit is below NBR_THREADS */
 			nbr_threads = (nbr_threads / 2) - 1;
 			/* Ensure we create at least a few threads! */
