projects
/
NextIRCd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
push
[NextIRCd.git]
/
src
/
ircd_auth.c
diff --git
a/src/ircd_auth.c
b/src/ircd_auth.c
index 22325f484e491da3072907098369ded701647b08..1645892042e434b3965ea2fc330a40a7d0297e60 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"
@@
-36,6
+37,7
@@
struct Auth *auth_new(struct Connection *conn) {
socket_printf(conn, "NOTICE AUTH :*** NextIRCd v%d.%d (%s)", VERSION_NUMBER, patchlevel, revision);
auth->conn = conn;
socket_printf(conn, "NOTICE AUTH :*** NextIRCd v%d.%d (%s)", VERSION_NUMBER, patchlevel, revision);
auth->conn = conn;
+ conn->data.auth = auth;
time(&auth->startup_time);
auth->prev = authlist_last;
time(&auth->startup_time);
auth->prev = authlist_last;
@@
-89,8
+91,8
@@
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;
auth->sent_ping = 1;
+ socket_printf(auth->conn, ":AUTH PING :%d", auth->startup_time);
} else if(auth->have_pong && auth->have_dnsresolv) {
struct Client *client = client_connected(auth);
auth->conn->authed = 1;
} else if(auth->have_pong && auth->have_dnsresolv) {
struct Client *client = client_connected(auth);
auth->conn->authed = 1;