aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Pittman <depittman@gmail.com>2007-04-16 20:32:14 +0000
committerDaniel Pittman <depittman@gmail.com>2007-04-16 20:32:14 +0000
commitc09343fb06be96edac01bbe48d8a269d898c91fd (patch)
tree1f4891e65fdc52213094fe6e45681c1e89c16e51
parent3b0f07d767b04dbdc8ff7a04f74521e14756e1ed (diff)
downloadlibmicrohttpd-c09343fb06be96edac01bbe48d8a269d898c91fd.tar.gz
libmicrohttpd-c09343fb06be96edac01bbe48d8a269d898c91fd.zip
Resolved Mantis bug ID:0001195
-rw-r--r--src/daemon/daemon.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/daemon/daemon.c b/src/daemon/daemon.c
index 8854d2bd..dd22ce6d 100644
--- a/src/daemon/daemon.c
+++ b/src/daemon/daemon.c
@@ -890,7 +890,7 @@ MHD_handle_write(int connection_id, struct MHD_Daemon * daemon) {
890 return MHD_NO; 890 return MHD_NO;
891 } 891 }
892 } 892 }
893 sprintf(responseMessage, "Content-length: %i\r\n\r\n", response->size); 893 sprintf(responseMessage, "Content-length: %llu\r\n\r\n", (unsigned long long)response->size);
894 fprintf(stderr, "%s\n", responseMessage); 894 fprintf(stderr, "%s\n", responseMessage);
895 if(send(session->socket_fd, responseMessage, strlen(responseMessage),0)!= strlen(responseMessage)) { 895 if(send(session->socket_fd, responseMessage, strlen(responseMessage),0)!= strlen(responseMessage)) {
896 fprintf(stderr, "Error! could not send an entire header in one call to send! unable to handle this case as of this time.\n"); 896 fprintf(stderr, "Error! could not send an entire header in one call to send! unable to handle this case as of this time.\n");
@@ -902,7 +902,7 @@ MHD_handle_write(int connection_id, struct MHD_Daemon * daemon) {
902 i = send(session->socket_fd, response->data+response->bytesSentSoFar, response->size-response->bytesSentSoFar,0); 902 i = send(session->socket_fd, response->data+response->bytesSentSoFar, response->size-response->bytesSentSoFar,0);
903 response->bytesSentSoFar += i; 903 response->bytesSentSoFar += i;
904 904
905 fprintf(stderr, "Sent %i bytes of data\nTotal to send is %i bytes\n", i, response->size); 905 fprintf(stderr, "Sent %i bytes of data\nTotal to send is %llu bytes\n", i, (unsigned long long)response->size);
906 906
907 if(response->bytesSentSoFar == response->size) { 907 if(response->bytesSentSoFar == response->size) {
908 session->currentResponses[session->currentResponse] = NULL; 908 session->currentResponses[session->currentResponse] = NULL;