diff --git a/dist.c b/dist.c index 4bb8e41..7746dad 100644 --- a/dist.c +++ b/dist.c @@ -115,7 +115,7 @@ void handle_new_connection(unsigned long p_connid,int fd) if(can_read(&fd,1,0)) { fdread=fd; fdwrite=fdin; } else { fdread=fdin; fdwrite=fd; } bytesread=read(fdread,databuffer,sizeof(databuffer)); - if(bytesread<=0||write(fdwrite,databuffer,bytesread)<=0); + if(bytesread<=0||write(fdwrite,databuffer,bytesread)<=0) { closeskt(fd); closeskt(fdin);