diff options
| author | osmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2006-07-12 09:14:46 +0000 |
|---|---|---|
| committer | osmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2006-07-12 09:14:46 +0000 |
| commit | 8a9f232945f6ec241470513933baf6d72d256a06 (patch) | |
| tree | 01c03798a9850c55f88a3e34db706a8786040482 /src/alphacode/poller | |
| parent | 62918b434f4f3c809505715d1d92c402110ab230 (diff) | |
| download | zabbix-8a9f232945f6ec241470513933baf6d72d256a06.tar.gz zabbix-8a9f232945f6ec241470513933baf6d72d256a06.tar.xz zabbix-8a9f232945f6ec241470513933baf6d72d256a06.zip | |
zabbix-1.2_dev integration
git-svn-id: svn://svn.zabbix.com/trunk@3038 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'src/alphacode/poller')
| -rw-r--r-- | src/alphacode/poller/poller.c | 2 | ||||
| -rwxr-xr-x | src/alphacode/poller/snmp.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/alphacode/poller/poller.c b/src/alphacode/poller/poller.c index a9574697..570cee64 100644 --- a/src/alphacode/poller/poller.c +++ b/src/alphacode/poller/poller.c @@ -138,7 +138,7 @@ void wait_connect() if ((poll_cli[i].revents&POLLOUT)==POLLOUT) { printf("[%d] remote socket ready for writing\n",i); - snprintf(c, 1024 - 1, "%s\n", "system.uptime\n"); + zbx_snprintf(c, sizeof(c), "%s\n", "system.uptime\n"); if( write(poll_cli[i].fd,c,strlen(c)) == -1 ) { perror("write"); diff --git a/src/alphacode/poller/snmp.c b/src/alphacode/poller/snmp.c index 9b29f77c..9f2bc583 100755 --- a/src/alphacode/poller/snmp.c +++ b/src/alphacode/poller/snmp.c @@ -121,7 +121,7 @@ void load_oids(void) struct host *h; struct oid *o; - sprintf(sql,"select h.ip,i.snmp_community,i.snmp_oid from hosts h,items i where i.hostid=h.hostid and i.type=1 and i.status=0 and h.status=0 and h.useip=1"); + zbx_snprintf(sql, sizeof(sql), "select h.ip,i.snmp_community,i.snmp_oid from hosts h,items i where i.hostid=h.hostid and i.type=1 and i.status=0 and h.status=0 and h.useip=1"); result=DBselect(sql); |
