diff options
author | Christian Grothoff <christian@grothoff.org> | 2008-09-11 03:50:35 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2008-09-11 03:50:35 +0000 |
commit | d550af2a104d21e7eb06f418a6fbb8a509266a37 (patch) | |
tree | 6dedfa111e15dbee0e0131a6b3227b71136d9fe8 | |
parent | 665502d76a87f4c1611cb05a387fd6f1941345a0 (diff) | |
download | libmicrohttpd-d550af2a104d21e7eb06f418a6fbb8a509266a37.tar.gz libmicrohttpd-d550af2a104d21e7eb06f418a6fbb8a509266a37.zip |
update
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | README | 23 | ||||
-rw-r--r-- | configure.ac | 4 | ||||
-rw-r--r-- | src/daemon/daemon.c | 39 |
4 files changed, 41 insertions, 29 deletions
@@ -1,3 +1,7 @@ | |||
1 | Wed Sep 10 21:36:06 MDT 2008 | ||
2 | Fixed data race on closing sockets during | ||
3 | shutdown (in one-thread-per-connection mode). -CG | ||
4 | |||
1 | Thu Sep 4 23:37:18 MDT 2008 | 5 | Thu Sep 4 23:37:18 MDT 2008 |
2 | Fixed some boundary issues with processing | 6 | Fixed some boundary issues with processing |
3 | chunked requests; removed memmove from a | 7 | chunked requests; removed memmove from a |
@@ -24,8 +24,9 @@ reporting (and use MHD_USE_DEBUG). Error reporting is not enabled by | |||
24 | default to reduce the size of the library (error messages take | 24 | default to reduce the size of the library (error messages take |
25 | space!). If you are concerned about space, you should set "CFLAGS" to | 25 | space!). If you are concerned about space, you should set "CFLAGS" to |
26 | "-Os -fomit-frame-pointer" to have gcc generate tight code. The | 26 | "-Os -fomit-frame-pointer" to have gcc generate tight code. The |
27 | resulting binary should be about 25k depending on the platform (I | 27 | resulting binary should be about 30k (without SSL support) depending |
28 | got 25884 bytes using "-march=pentium4"). | 28 | on the platform. |
29 | |||
29 | 30 | ||
30 | Portability | 31 | Portability |
31 | =========== | 32 | =========== |
@@ -64,16 +65,14 @@ Development Status | |||
64 | 65 | ||
65 | This is a beta release. Below we list things that should be | 66 | This is a beta release. Below we list things that should be |
66 | implemented (in order of importance) before we can claim to be | 67 | implemented (in order of importance) before we can claim to be |
67 | reasonably complete. #XXXX refers to the respective Mantis bug report | 68 | reasonably complete. |
68 | (or feature request). | ||
69 | |||
70 | 69 | ||
71 | 70 | ||
72 | Missing features: | 71 | Missing features: |
73 | ================= | 72 | ================= |
74 | - SSL support: | 73 | - SSL code is still too large (plenty of dead or |
75 | * documentation | 74 | unnecessary code imported from gnuTLS) |
76 | * more testing | 75 | - Make sure SSL works on non-GNU/Linux platforms |
77 | 76 | ||
78 | 77 | ||
79 | Untested features: | 78 | Untested features: |
@@ -87,12 +86,18 @@ Untested features: | |||
87 | suppressing 100 CONTINUE | 86 | suppressing 100 CONTINUE |
88 | - extend testcase for chunked encoding to validate | 87 | - extend testcase for chunked encoding to validate |
89 | handling of footers | 88 | handling of footers |
89 | - more testing for SSL support | ||
90 | 90 | ||
91 | 91 | ||
92 | Missing documentation: | 92 | Missing documentation: |
93 | ====================== | 93 | ====================== |
94 | - manual (SSL/TLS support) | 94 | |
95 | - manual: | ||
96 | * document configuration options | ||
97 | * document SSL/TLS support | ||
98 | * document details on porting MHD (plibc, z/OS) | ||
95 | - tutorial: | 99 | - tutorial: |
96 | * clean up English | 100 | * clean up English |
97 | * make sure everything is accurate | 101 | * make sure everything is accurate |
98 | * change example code to follow GNU coding conventions | 102 | * change example code to follow GNU coding conventions |
103 | * provide examples for using SSL | ||
diff --git a/configure.ac b/configure.ac index 344a95f4..4fd23141 100644 --- a/configure.ac +++ b/configure.ac | |||
@@ -21,8 +21,8 @@ | |||
21 | # | 21 | # |
22 | # | 22 | # |
23 | AC_PREREQ(2.57) | 23 | AC_PREREQ(2.57) |
24 | AC_INIT([libmicrohttpd], [0.3.1],[libmicrohttpd@gnunet.org]) | 24 | AC_INIT([libmicrohttpd], [0.4.0pre0],[libmicrohttpd@gnunet.org]) |
25 | AM_INIT_AUTOMAKE([libmicrohttpd], [0.3.1]) | 25 | AM_INIT_AUTOMAKE([libmicrohttpd], [0.4.0pre0]) |
26 | AM_CONFIG_HEADER([MHD_config.h]) | 26 | AM_CONFIG_HEADER([MHD_config.h]) |
27 | 27 | ||
28 | AH_TOP([#define _GNU_SOURCE 1]) | 28 | AH_TOP([#define _GNU_SOURCE 1]) |
diff --git a/src/daemon/daemon.c b/src/daemon/daemon.c index 34a94922..950239a6 100644 --- a/src/daemon/daemon.c +++ b/src/daemon/daemon.c | |||
@@ -597,32 +597,35 @@ MHD_cleanup_connections (struct MHD_Daemon *daemon) | |||
597 | prev = NULL; | 597 | prev = NULL; |
598 | while (pos != NULL) | 598 | while (pos != NULL) |
599 | { | 599 | { |
600 | if (pos->socket_fd == -1) | 600 | if ( (pos->socket_fd == -1) || |
601 | { | 601 | ( ( (0 != (daemon->options & MHD_USE_THREAD_PER_CONNECTION)) && |
602 | (daemon->shutdown) && | ||
603 | (pos->socket_fd != -1) ) ) ) | ||
604 | { | ||
602 | if (prev == NULL) | 605 | if (prev == NULL) |
603 | daemon->connections = pos->next; | 606 | daemon->connections = pos->next; |
604 | else | 607 | else |
605 | prev->next = pos->next; | 608 | prev->next = pos->next; |
606 | if (0 != (daemon->options & MHD_USE_THREAD_PER_CONNECTION)) | 609 | if (0 != (pos->daemon->options & MHD_USE_THREAD_PER_CONNECTION)) |
607 | { | 610 | { |
608 | pthread_kill (pos->pid, SIGALRM); | 611 | pthread_kill (pos->pid, SIGALRM); |
609 | pthread_join (pos->pid, &unused); | 612 | pthread_join (pos->pid, &unused); |
610 | } | 613 | } |
611 | MHD_destroy_response (pos->response); | 614 | MHD_destroy_response (pos->response); |
612 | MHD_pool_destroy (pos->pool); | 615 | MHD_pool_destroy (pos->pool); |
613 | #if HTTPS_SUPPORT | 616 | #if HTTPS_SUPPORT |
614 | if (pos->tls_session != NULL) | 617 | if (pos->tls_session != NULL) |
615 | MHD_gnutls_deinit (pos->tls_session); | 618 | MHD_gnutls_deinit (pos->tls_session); |
616 | #endif | 619 | #endif |
617 | free (pos->addr); | 620 | free (pos->addr); |
618 | free (pos); | 621 | free (pos); |
619 | daemon->max_connections++; | 622 | daemon->max_connections++; |
620 | if (prev == NULL) | 623 | if (prev == NULL) |
621 | pos = daemon->connections; | 624 | pos = daemon->connections; |
622 | else | 625 | else |
623 | pos = prev->next; | 626 | pos = prev->next; |
624 | continue; | 627 | continue; |
625 | } | 628 | } |
626 | prev = pos; | 629 | prev = pos; |
627 | pos = pos->next; | 630 | pos = pos->next; |
628 | } | 631 | } |