diff options
author | Christian Grothoff <christian@grothoff.org> | 2008-11-15 07:34:18 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2008-11-15 07:34:18 +0000 |
commit | 5d9a9723b3269dc58600d526dc719fa0bd525d3c (patch) | |
tree | 99526234bad906cec0dce0ec4c17f54ca3950977 /src/daemon/daemon.c | |
parent | e460b1507c74c3d16b8e3cfee2f37e000c4b0159 (diff) | |
download | libmicrohttpd-5d9a9723b3269dc58600d526dc719fa0bd525d3c.tar.gz libmicrohttpd-5d9a9723b3269dc58600d526dc719fa0bd525d3c.zip |
removing broken and/or dead code
Diffstat (limited to 'src/daemon/daemon.c')
-rw-r--r-- | src/daemon/daemon.c | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/src/daemon/daemon.c b/src/daemon/daemon.c index b9e2a5a8..a0a50992 100644 --- a/src/daemon/daemon.c +++ b/src/daemon/daemon.c | |||
@@ -153,15 +153,6 @@ MHD_TLS_init (struct MHD_Daemon *daemon) | |||
153 | { | 153 | { |
154 | switch (daemon->cred_type) | 154 | switch (daemon->cred_type) |
155 | { | 155 | { |
156 | case MHD_GNUTLS_CRD_ANON: | ||
157 | if ((0 != | ||
158 | MHD__gnutls_anon_allocate_server_credentials (&daemon->anon_cred)) | ||
159 | || (0 != MHD__gnutls_dh_params_init (&daemon->dh_params))) | ||
160 | return GNUTLS_E_MEMORY_ERROR; | ||
161 | MHD__gnutls_dh_params_generate2 (daemon->dh_params, 1024); | ||
162 | MHD__gnutls_anon_set_server_dh_params (daemon->anon_cred, | ||
163 | daemon->dh_params); | ||
164 | return 0; | ||
165 | case MHD_GNUTLS_CRD_CERTIFICATE: | 156 | case MHD_GNUTLS_CRD_CERTIFICATE: |
166 | if (0 != | 157 | if (0 != |
167 | MHD__gnutls_certificate_allocate_credentials (&daemon->x509_cred)) | 158 | MHD__gnutls_certificate_allocate_credentials (&daemon->x509_cred)) |
@@ -495,13 +486,6 @@ MHD_accept_connection (struct MHD_Daemon *daemon) | |||
495 | MHD_GNUTLS_CRD_CERTIFICATE, | 486 | MHD_GNUTLS_CRD_CERTIFICATE, |
496 | connection->daemon->x509_cred); | 487 | connection->daemon->x509_cred); |
497 | break; | 488 | break; |
498 | case MHD_GNUTLS_CRD_ANON: | ||
499 | /* set needed credentials for anonymous authentication. */ | ||
500 | MHD__gnutls_credentials_set (connection->tls_session, | ||
501 | MHD_GNUTLS_CRD_ANON, | ||
502 | connection->daemon->anon_cred); | ||
503 | MHD__gnutls_dh_set_prime_bits (connection->tls_session, 1024); | ||
504 | break; | ||
505 | default: | 489 | default: |
506 | #if HAVE_MESSAGES | 490 | #if HAVE_MESSAGES |
507 | MHD_DLOG (connection->daemon, | 491 | MHD_DLOG (connection->daemon, |
@@ -1101,8 +1085,6 @@ MHD_stop_daemon (struct MHD_Daemon *daemon) | |||
1101 | MHD__gnutls_priority_deinit (daemon->priority_cache); | 1085 | MHD__gnutls_priority_deinit (daemon->priority_cache); |
1102 | if (daemon->x509_cred) | 1086 | if (daemon->x509_cred) |
1103 | MHD__gnutls_certificate_free_credentials (daemon->x509_cred); | 1087 | MHD__gnutls_certificate_free_credentials (daemon->x509_cred); |
1104 | if (daemon->anon_cred) | ||
1105 | MHD__gnutls_anon_free_server_credentials (daemon->anon_cred); | ||
1106 | /* lock MHD_gnutls_global mutex since it uses reference counting */ | 1088 | /* lock MHD_gnutls_global mutex since it uses reference counting */ |
1107 | pthread_mutex_lock (&MHD_gnutls_init_mutex); | 1089 | pthread_mutex_lock (&MHD_gnutls_init_mutex); |
1108 | MHD__gnutls_global_deinit (); | 1090 | MHD__gnutls_global_deinit (); |