restrict read() to 160 char

This commit is contained in:
Gregory Colpart 2007-07-03 14:52:53 +00:00
parent 91e1073f69
commit 974d600c09
1 changed files with 2 additions and 2 deletions

View File

@ -94,9 +94,9 @@ int main(void) {
printf("error in tcp connection init : %s\n",strerror(errsv));
}
// get data
// get data (only 160 first char)
memset(&buf,0,BUFSIZ);
bytes_read = read(fd,buf,BUFSIZ);
bytes_read = read(fd,buf,160);
// url encoding
memset(&encbuf,0,BUFSIZ);