Procházet zdrojové kódy

snmpstats: replace STR_PARAM with PARAM_STRING

Alekzander Spiridonov před 11 roky
rodič
revize
8926ebbdc9

+ 1 - 1
modules/snmpstats/snmpSIPCommonObjects.c

@@ -456,7 +456,7 @@ int handle_kamailioSIPOtherwiseDiscardedMsgs(netsnmp_mib_handler *handler,
  * Parameter Setting Functions 
  */
 
-/* If type==STR_PARAM and stringParam is valid, this function will overwrite
+/* If type==PARAM_STRING and stringParam is valid, this function will overwrite
  * kamailioEntityType with a bit value corresponding to the IETF's RFC  for 
  * the SIP MIB.  (Textual Convention SipEntityRole).  Anything else is
  * considered an error.

+ 3 - 3
modules/snmpstats/snmpstats.c

@@ -143,7 +143,7 @@ static proc_export_t mod_procs[] = {
  */
 static param_export_t mod_params[] =
 {
-	{ "sipEntityType",          STR_PARAM|USE_FUNC_PARAM,
+	{ "sipEntityType",          PARAM_STRING|USE_FUNC_PARAM,
 			(void *)handleSipEntityType       },
 	{ "MsgQueueMinorThreshold", INT_PARAM|USE_FUNC_PARAM,
 			(void *)set_queue_minor_threshold },
@@ -153,9 +153,9 @@ static param_export_t mod_params[] =
 			(void *)set_dlg_minor_threshold   },
 	{ "dlg_major_threshold",    INT_PARAM|USE_FUNC_PARAM,
 			(void *)set_dlg_major_threshold   },
-	{ "snmpgetPath",            STR_PARAM|USE_FUNC_PARAM,
+	{ "snmpgetPath",            PARAM_STRING|USE_FUNC_PARAM,
 			(void *)set_snmpget_path          },
-	{ "snmpCommunity",          STR_PARAM|USE_FUNC_PARAM,
+	{ "snmpCommunity",          PARAM_STRING|USE_FUNC_PARAM,
 			(void *)set_snmp_community        },
 	{ "export_registrar",       INT_PARAM,
 			&snmp_export_registrar            },

+ 2 - 2
modules/snmpstats/utilities.c

@@ -84,9 +84,9 @@ int stringHandlerSanityCheck( modparam_t type, void *val, char *parameterName)
 	char *theString = (char *)val;
 
 	/* Make sure the function was called correctly. */
-	if (PARAM_TYPE_MASK(type) != STR_PARAM) {
+	if (PARAM_TYPE_MASK(type) != PARAM_STRING) {
 		LM_ERR("the %s parameter was assigned a type %d instead of %d\n",
-				parameterName, type, STR_PARAM);
+				parameterName, type, PARAM_STRING);
 		return 0;
 	}