summaryrefslogtreecommitdiffstats
path: root/src/zabbix_server/server.c
diff options
context:
space:
mode:
authorhugetoad <hugetoad@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2005-04-26 11:48:13 +0000
committerhugetoad <hugetoad@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2005-04-26 11:48:13 +0000
commit2973a6bc6fd2460274838959a94d7eff598f34f1 (patch)
tree3459f5fb34ec2e93b30e702517f494ab8251819c /src/zabbix_server/server.c
parent8fed3882dbfb4395dd2b590847d3dd628ead1c5c (diff)
downloadzabbix-2973a6bc6fd2460274838959a94d7eff598f34f1.tar.gz
zabbix-2973a6bc6fd2460274838959a94d7eff598f34f1.tar.xz
zabbix-2973a6bc6fd2460274838959a94d7eff598f34f1.zip
Minor changes.
git-svn-id: svn://svn.zabbix.com/trunk@1725 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'src/zabbix_server/server.c')
-rw-r--r--src/zabbix_server/server.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/zabbix_server/server.c b/src/zabbix_server/server.c
index ff7e205a..f7705126 100644
--- a/src/zabbix_server/server.c
+++ b/src/zabbix_server/server.c
@@ -1146,7 +1146,10 @@ void process_trapper_child(int sockfd)
zabbix_log( LOG_LEVEL_DEBUG, "After read() 2 [%d]",nread);
- line[nread-1]=0;
+ if(nread>0)
+ {
+ line[nread-1]=0;
+ }
zabbix_log( LOG_LEVEL_DEBUG, "Got line:%s", line);
if( SUCCEED == process_trap(sockfd,line) )