projects
/
NextIRCd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
4ec553e
)
push
author
pk910
<philipp@zoelle1.de>
Thu, 15 Jan 2015 17:03:46 +0000
(18:03 +0100)
committer
pk910
<philipp@zoelle1.de>
Thu, 15 Jan 2015 17:03:46 +0000
(18:03 +0100)
configure.ac
patch
|
blob
|
history
src/ircd_auth.c
patch
|
blob
|
history
diff --git
a/configure.ac
b/configure.ac
index aa5b500c48416c132aef6208d20914ec46576a36..f0bc9a63c1f518594b344704a7db2ebf6f054824 100644
(file)
--- a/
configure.ac
+++ b/
configure.ac
@@
-35,15
+35,23
@@
AC_FUNC_MALLOC
AC_CHECK_FUNCS([usleep select socket inet_pton inet_ntop])
AC_CHECK_HEADERS([fcntl.h sys/socket.h sys/select.h sys/time.h sys/types.h unistd.h windows.h winsock2.h errno.h sys/epoll.h sys/event.h])
AC_CHECK_FUNCS([usleep select socket inet_pton inet_ntop])
AC_CHECK_HEADERS([fcntl.h sys/socket.h sys/select.h sys/time.h sys/types.h unistd.h windows.h winsock2.h errno.h sys/epoll.h sys/event.h])
-AC_CHECK_LIB(ws2_32, main, [ LIBS="$LIBS -lws2_32" ], [])
-
-AC_CHECK_LIB(ssl, SSL_read, [
- AC_CHECK_LIB(crypto, X509_new, [
- AC_CHECK_HEADERS(openssl/ssl.h openssl/err.h openssl/rand.h, [
- LIBS="$LIBS -lssl -lcrypto"
- ])
- ])
+AC_CHECK_LIB(ws2_32, main, [
+ LIBS="$LIBS -lws2_32"
+ is_win32="yes"
+], [
+ is_win32="no"
])
])
+
+if test x$is_win32 = xyes ; then
+ openssl_deps="-lcrypto -lgdi32"
+else
+ openssl_deps="-lcrypto"
+fi
+
+AC_CHECK_LIB([ssl],[SSL_library_init], [
+ LIBS="$LIBS -lssl $openssl_deps"
+], [AC_MSG_ERROR([OpenSSL libraries required])], $openssl_deps)
+
AC_CHECK_LIB(pthread, pthread_create, [
AC_CHECK_HEADERS(pthread.h, [
LIBS="$LIBS -lpthread"
AC_CHECK_LIB(pthread, pthread_create, [
AC_CHECK_HEADERS(pthread.h, [
LIBS="$LIBS -lpthread"
diff --git
a/src/ircd_auth.c
b/src/ircd_auth.c
index 22325f484e491da3072907098369ded701647b08..5634038747e984b09e4b04ca31fffc9e6e89b495 100644
(file)
--- a/
src/ircd_auth.c
+++ b/
src/ircd_auth.c
@@
-17,6
+17,7
@@
#include <string.h>
#include "ircd_auth.h"
#include <string.h>
#include "ircd_auth.h"
+#include "ircd_sock.h"
#include "struct_auth.h"
#include "struct_connection.h"
#include "ircd_client.h"
#include "struct_auth.h"
#include "struct_connection.h"
#include "ircd_client.h"
@@
-89,7
+90,6
@@
void auth_try_finish(struct Auth *auth) {
if(!auth->have_nick || !auth->have_user)
return;
if(!auth->sent_ping) {
if(!auth->have_nick || !auth->have_user)
return;
if(!auth->sent_ping) {
-
auth->sent_ping = 1;
} else if(auth->have_pong && auth->have_dnsresolv) {
struct Client *client = client_connected(auth);
auth->sent_ping = 1;
} else if(auth->have_pong && auth->have_dnsresolv) {
struct Client *client = client_connected(auth);