Added debu output

Signed-off-by: Tyrolyean <tyrolyean@tyrolyean.net>
This commit is contained in:
Tyrolyean 2020-04-26 22:15:20 +02:00
parent f8f513145d
commit 76c4529999
No known key found for this signature in database
GPG Key ID: 81EC9BAC5E9667C6
1 changed files with 3 additions and 2 deletions

View File

@ -89,10 +89,11 @@ void* client_handle_async(void* params){
}
bzero(buf, sizeof(buf));
n = read(fds[i].fd, buf, sizeof(buf));
n = read(fds[i].fd, buf, sizeof(buf)-1);
if (n <= 0) {
goto closeup;
}
printf("%lu:[%s]", i, buf);
if(i==0 && !in_body){
@ -119,7 +120,7 @@ void* client_handle_async(void* params){
}
} else if(i==0 && !after_body){
/* We keep the body until we have it completetly
/* We keep the body until we have it completely
*/
in_len += n;
input_buffer = realloc(input_buffer, in_len);