Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/zabbix/zabbix.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/libs/zbxsysinfo/freebsd/net.c')
-rw-r--r--src/libs/zbxsysinfo/freebsd/net.c19
1 files changed, 10 insertions, 9 deletions
diff --git a/src/libs/zbxsysinfo/freebsd/net.c b/src/libs/zbxsysinfo/freebsd/net.c
index 02680ea733e..d4d3dfeea40 100644
--- a/src/libs/zbxsysinfo/freebsd/net.c
+++ b/src/libs/zbxsysinfo/freebsd/net.c
@@ -18,6 +18,7 @@
**/
#include "zbxsysinfo.h"
+#include "../sysinfo.h"
#include "../common/zbxsysinfo_common.h"
#include "zbxjson.h"
@@ -75,7 +76,7 @@ static int get_ifmib_general(const char *if_name, char **error)
return FAIL;
}
-int NET_IF_IN(AGENT_REQUEST *request, AGENT_RESULT *result)
+int net_if_in(AGENT_REQUEST *request, AGENT_RESULT *result)
{
char *if_name, *mode, *error;
@@ -111,7 +112,7 @@ int NET_IF_IN(AGENT_REQUEST *request, AGENT_RESULT *result)
return SYSINFO_RET_OK;
}
-int NET_IF_OUT(AGENT_REQUEST *request, AGENT_RESULT *result)
+int net_if_out(AGENT_REQUEST *request, AGENT_RESULT *result)
{
char *if_name, *mode, *error;
@@ -145,7 +146,7 @@ int NET_IF_OUT(AGENT_REQUEST *request, AGENT_RESULT *result)
return SYSINFO_RET_OK;
}
-int NET_IF_TOTAL(AGENT_REQUEST *request, AGENT_RESULT *result)
+int net_if_total(AGENT_REQUEST *request, AGENT_RESULT *result)
{
char *if_name, *mode, *error;
@@ -179,7 +180,7 @@ int NET_IF_TOTAL(AGENT_REQUEST *request, AGENT_RESULT *result)
return SYSINFO_RET_OK;
}
-int NET_TCP_LISTEN(AGENT_REQUEST *request, AGENT_RESULT *result)
+int net_tcp_listen(AGENT_REQUEST *request, AGENT_RESULT *result)
{
char *port_str, command[64];
unsigned short port;
@@ -201,7 +202,7 @@ int NET_TCP_LISTEN(AGENT_REQUEST *request, AGENT_RESULT *result)
zbx_snprintf(command, sizeof(command), "netstat -an | grep '^tcp.*\\.%hu[^.].*LISTEN' | wc -l", port);
- if (SYSINFO_RET_FAIL == (res = EXECUTE_INT(command, result)))
+ if (SYSINFO_RET_FAIL == (res = execute_int(command, result)))
return res;
if (1 < result->ui64)
@@ -210,7 +211,7 @@ int NET_TCP_LISTEN(AGENT_REQUEST *request, AGENT_RESULT *result)
return res;
}
-int NET_UDP_LISTEN(AGENT_REQUEST *request, AGENT_RESULT *result)
+int net_udp_listen(AGENT_REQUEST *request, AGENT_RESULT *result)
{
char *port_str, command[64];
unsigned short port;
@@ -232,7 +233,7 @@ int NET_UDP_LISTEN(AGENT_REQUEST *request, AGENT_RESULT *result)
zbx_snprintf(command, sizeof(command), "netstat -an | grep '^udp.*\\.%hu[^.].*\\*\\.\\*' | wc -l", port);
- if (SYSINFO_RET_FAIL == (res = EXECUTE_INT(command, result)))
+ if (SYSINFO_RET_FAIL == (res = execute_int(command, result)))
return res;
if (1 < result->ui64)
@@ -241,7 +242,7 @@ int NET_UDP_LISTEN(AGENT_REQUEST *request, AGENT_RESULT *result)
return res;
}
-int NET_IF_COLLISIONS(AGENT_REQUEST *request, AGENT_RESULT *result)
+int net_if_collisions(AGENT_REQUEST *request, AGENT_RESULT *result)
{
char *if_name, *error;
@@ -264,7 +265,7 @@ int NET_IF_COLLISIONS(AGENT_REQUEST *request, AGENT_RESULT *result)
return SYSINFO_RET_OK;
}
-int NET_IF_DISCOVERY(AGENT_REQUEST *request, AGENT_RESULT *result)
+int net_if_discovery(AGENT_REQUEST *request, AGENT_RESULT *result)
{
int i;
struct zbx_json j;