diff options
| author | hugetoad <hugetoad@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2005-10-06 11:10:10 +0000 |
|---|---|---|
| committer | hugetoad <hugetoad@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2005-10-06 11:10:10 +0000 |
| commit | 000e87fbe9f1d11a5e3eae76a13fb8ab94ca683d (patch) | |
| tree | 003e6353b52ba7d5221d42abf09b108569344fca /src/libs | |
| parent | 449e4355f20d8bd72f9019ca82f14a4716ec58cf (diff) | |
- fixed compilation issues of Unix agent on non-Linux platforms (Alexei)
git-svn-id: svn://svn.zabbix.com/trunk@2126 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'src/libs')
| -rw-r--r-- | src/libs/zbxsysinfo/sysinfo.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/libs/zbxsysinfo/sysinfo.c b/src/libs/zbxsysinfo/sysinfo.c index 042f1330..d409be26 100644 --- a/src/libs/zbxsysinfo/sysinfo.c +++ b/src/libs/zbxsysinfo/sysinfo.c @@ -2025,11 +2025,17 @@ int CHECK_DNS(const char *cmd, const char *ip_and_zone,double *value) _res.nsaddr_list[0].sin_addr = in; _res.nsaddr_list[0].sin_family = AF_INET; - _res.nsaddr_list[0].sin_port = htons(NS_DEFAULTPORT); +/* _res.nsaddr_list[0].sin_port = htons(NS_DEFAULTPORT);*/ + + _res.nsaddr_list[0].sin_port = htons(53); _res.nscount = 1; _res.retrans=5; +#ifdef C_IN + result=res_query(zone,C_IN,T_SOA,respbuf,sizeof(respbuf)); +#else result=res_query(zone,ns_c_in,ns_t_soa,respbuf,sizeof(respbuf)); +#endif *value = result!=-1 ? 1 : 0; return SYSINFO_RET_OK; |
